Updated Branches: refs/heads/master 77e691932 -> bf5cea2fe
Use a smaller and simpler input for the NLineInputIT Project: http://git-wip-us.apache.org/repos/asf/incubator-crunch/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-crunch/commit/bf5cea2f Tree: http://git-wip-us.apache.org/repos/asf/incubator-crunch/tree/bf5cea2f Diff: http://git-wip-us.apache.org/repos/asf/incubator-crunch/diff/bf5cea2f Branch: refs/heads/master Commit: bf5cea2fe24150fc3f8b2ad3c65de7ee732a4631 Parents: 77e6919 Author: Josh Wills <[email protected]> Authored: Sun Dec 9 23:35:30 2012 -0800 Committer: Josh Wills <[email protected]> Committed: Sun Dec 9 23:35:30 2012 -0800 ---------------------------------------------------------------------- .../it/java/org/apache/crunch/io/NLineInputIT.java | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-crunch/blob/bf5cea2f/crunch/src/it/java/org/apache/crunch/io/NLineInputIT.java ---------------------------------------------------------------------- diff --git a/crunch/src/it/java/org/apache/crunch/io/NLineInputIT.java b/crunch/src/it/java/org/apache/crunch/io/NLineInputIT.java index 3b7abf6..6b16aa8 100644 --- a/crunch/src/it/java/org/apache/crunch/io/NLineInputIT.java +++ b/crunch/src/it/java/org/apache/crunch/io/NLineInputIT.java @@ -39,12 +39,12 @@ public class NLineInputIT { @Test public void testNLine() throws Exception { - String shakesInputPath = tmpDir.copyResourceFileName("shakes.txt"); + String urlsInputPath = tmpDir.copyResourceFileName("urls.txt"); Pipeline pipeline = new MRPipeline(NLineInputIT.class, tmpDir.getDefaultConfiguration()); - PCollection<String> shakespeare = pipeline.read(new NLineFileSource<String>(shakesInputPath, - Writables.strings(), 100)); - assertEquals(new Integer(100), - shakespeare.parallelDo(new LineCountFn(), Avros.ints()).max().getValue()); + PCollection<String> urls = pipeline.read(new NLineFileSource<String>(urlsInputPath, + Writables.strings(), 2)); + assertEquals(new Integer(2), + urls.parallelDo(new LineCountFn(), Avros.ints()).max().getValue()); } private static class LineCountFn extends DoFn<String, Integer> {
