public static Split split(String regex) {
    return split(Pattern.compile(regex), false);
  }
@Test
  @Category(NeedsRunner.class)
  public void testSplits() {

    PCollection<String> output =
        p.apply(Create.of("The  quick   brown fox jumps over    the lazy dog"))
            .apply(Regex.split("\\W+"));

    PAssert.that(output)
        .containsInAnyOrder("The", "quick", "brown", "fox", "jumps", "over", "the", "lazy", "dog");
    p.run();
  }