Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parallel runner causes duplicate GET, POST, DELETE requests to happen #834

Closed
ghost opened this issue Jul 19, 2019 · 5 comments
Closed

Parallel runner causes duplicate GET, POST, DELETE requests to happen #834

ghost opened this issue Jul 19, 2019 · 5 comments
Labels

Comments

@ghost
Copy link

ghost commented Jul 19, 2019

When using the parallel test runner, multiple POST's get executed. The code below uses the Post Test Server V2 to submit a POST to and you can see that 2 posts are submitted.

Note the test runner is NOT using the @RunWith(Karate.class) annotation and using the junit:4.12 transient dependency from karate-junit4:0.9.3

Karate v0.9.3

Feature file:

    * def REQUEST = {type: 'test-type', name: 'test-name'}
    Given url 'https://ptsv2.com/t/paowv-1563551220/post'
    And request REQUEST
    When method POST
    Then status 200

Parallel Test Runner file:

import static org.junit.Assert.assertTrue;
import com.intuit.karate.Results;
import com.intuit.karate.Runner;
import org.junit.Test;

public class ApiTest {
    @Test
    public void testParallel() {
        Results results = Runner.parallel(getClass(), 5, "target/surefire-reports");
        assertTrue(results.getErrorMessages(), results.getFailCount() == 0);
    }
}
@ptrthomas
Copy link
Member

sorry I insist that you submit a full working example, there are reasons: https://github.com/intuit/karate/wiki/How-to-Submit-an-Issue

@ghost
Copy link
Author

ghost commented Aug 28, 2019

@ptrthomas I wish you would reconsider this issue. I feel that I have provided you everything needed to demonstrate the behavior.

@ptrthomas
Copy link
Member

@kendall-schmidt-sp I wish you would read and understand the link above.

that said, it is quite likely to be this issue: #861 - so try 0.9.5.RC1 and see if that works

@ghost
Copy link
Author

ghost commented Aug 29, 2019

@ptrthomas I did read and do understand the link. IMHO I feel it is heavy handed in some cases. I do understand that projects are prone to get poor bug reports - i.e. little to no details on how to reproduce the issue or they simply come across as a "complaint". I don't feel that I've done that.

I will take a look at #861 and give 0.9.5.RC1 a try and let you know if works. I appreciate this info.

@ptrthomas
Copy link
Member

@kendall-schmidt-sp I'm sorry you feel that way because I thought "why a working project is needed" was very clear. anyway it is up to you how you want to proceed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant