Github user MikeThomsen commented on a diff in the pull request:
https://github.com/apache/nifi/pull/2745#discussion_r191388975
--- Diff:
nifi-nar-bundles/nifi-standard-services/nifi-lookup-services-bundle/nifi-lookup-services/src/test/java/org/apache/nifi/lookup/TestSimpleCsvFileLookupService.java
---
@@ -64,4 +64,28 @@ public void testSimpleCsvFileLookupService() throws
InitializationException, IOE
assertEquals(EMPTY_STRING, property3);
}
+ @Test
+ public void testSimpleCsvFileLookupServiceWithCharset() throws
InitializationException, IOException, LookupFailureException {
+ final TestRunner runner =
TestRunners.newTestRunner(TestProcessor.class);
+ final SimpleCsvFileLookupService service = new
SimpleCsvFileLookupService();
+
+ runner.addControllerService("csv-file-lookup-service", service);
+ runner.setProperty(service, SimpleCsvFileLookupService.CSV_FILE,
"src/test/resources/test_Windows-31J.csv");
+ runner.setProperty(service, SimpleCsvFileLookupService.CSV_FORMAT,
"RFC4180");
+ runner.setProperty(service, SimpleCsvFileLookupService.CHARSET,
"Windows-31J");
+ runner.setProperty(service,
SimpleCsvFileLookupService.LOOKUP_KEY_COLUMN, "key");
+ runner.setProperty(service,
SimpleCsvFileLookupService.LOOKUP_VALUE_COLUMN, "value");
+ runner.enableControllerService(service);
+ runner.assertValid(service);
+
+ final SimpleCsvFileLookupService lookupService =
--- End diff --
These blocks can be removed.
---