kennknowles opened a new issue, #18391:
URL: https://github.com/apache/beam/issues/18391

   https://beam.apache.org/documentation/pipelines/test-your-pipeline/ has
   
   ```
   
    public void testCountWords() throws Exception {
         Pipeline p = TestPipeline.create();
   
   ```
   
   
   but this results in 
   
   ```
   
   Exception in thread "main" java.lang.IllegalStateException: Is your 
TestPipeline declaration missing
   a @Rule annotation? Usage: @Rule public final transient TestPipeline 
pipeline = TestPipeline.Create();
        at
   
org.apache.beam.sdk.repackaged.com.google.common.base.Preconditions.checkState(Preconditions.java:444)
        at
   org.apache.beam.sdk.testing.TestPipeline.run(TestPipeline.java:299)
        at BasicPipelineTest.run(BasicPipelineTest.java:42)
        at
   Main.main(Main.java:25)
   
   ```
   
   
   In the [github 
example](https://github.com/apache/beam/blob/master/examples/java8/src/test/java/org/apache/beam/examples/MinimalWordCountJava8Test.java#L56)
    it's written as:
   
   
   
   ```
   
   public TestPipeline p = 
TestPipeline.create().enableAbandonedNodeEnforcement(false);
   
   ```
   
   
   I'm using 2.0.0 from the maven repo.
   
   
   Imported from Jira 
[BEAM-2358](https://issues.apache.org/jira/browse/BEAM-2358). Original Jira may 
contain additional context.
   Reported by: nicku33.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to