@@ -0,0 +1,1600 @@
+package com.cloudera.dataflow.spark;%0A%0Aimport com.google.cloud.dataflow.sdk.Pipeline;%0Aimport com.google.cloud.dataflow.sdk.coders.StringUtf8Coder;%0Aimport com.google.cloud.dataflow.sdk.options.PipelineOptionsFactory;%0Aimport com.google.cloud.dataflow.sdk.transforms.Create;%0Aimport com.google.cloud.dataflow.sdk.transforms.RemoveDuplicates;%0Aimport com.google.cloud.dataflow.sdk.values.PCollection;%0Aimport com.google.common.collect.ImmutableSet;%0Aimport java.util.Arrays;%0Aimport java.util.HashSet;%0Aimport java.util.List;%0Aimport java.util.Set;%0Aimport org.junit.Assert;%0Aimport org.junit.Test;%0A%0A/**%0A * A test based on %7B@code DeDupExample%7D from the SDK.%0A */%0Apublic class DeDupTest %7B%0A%0A  private static final String%5B%5D LINES_ARRAY = %7B%0A      %22hi there%22, %22hello%22, %22hi there%22,%0A      %22hi%22, %22hello%22%7D;%0A  private static final List%3CString%3E LINES = Arrays.asList(LINES_ARRAY);%0A  private static final Set%3CString%3E EXPECTED_SET =%0A      ImmutableSet.of(%22hi there%22, %22hi%22, %22hello%22);%0A%0A  @Test%0A  public void testRun() throws Exception %7B%0A    Pipeline p = Pipeline.create(PipelineOptionsFactory.create());%0A    PCollection%3CString%3E input = p.apply(Create.of(LINES)).setCoder(StringUtf8Coder.of());%0A    PCollection%3CString%3E output = input.apply(RemoveDuplicates.%3CString%3Ecreate());%0A    EvaluationResult res = SparkPipelineRunner.create().run(p);%0A    Set%3CString%3E actualSet = new HashSet%3C%3E();%0A    for (String s : res.get(output)) %7B%0A      actualSet.add(s);%0A    %7D%0A%0A    Assert.assertEquals(String.format(%22Actual lines %5B%25s%5D does not equal expected %5B%25s%5D.%22,%0A            actualSet, EXPECTED_SET), EXPECTED_SET, actualSet);%0A    res.close();%0A  %7D%0A%7D%0A

Add test that uses DeDupExample from the SDK.