question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Exit signal is 0 even if assertions do not pass with bundle on Windows

See original GitHub issue

Hi!

I am running into a problem with Gatling when ran on a Jenkins slave using Windows Server R2.

The exit code is 0 even if the assertions fail. I have attached the test case and the output. The last line in the output is there because I am running echo Gatling exited with: %errorlevel% after Gatling has executed.

Simulation intel.WSMPRead completed in 15 seconds
Parsing log file(s)...
Parsing log file(s) done
Generating reports...

================================================================================
---- Global Information --------------------------------------------------------
> request count                                       2000 (OK=99     KO=1901  )
> min response time                                   2797 (OK=2797   KO=3116  )
> max response time                                  15079 (OK=8616   KO=15079 )
> mean response time                                 12146 (OK=6180   KO=12457 )
> std deviation                                       3141 (OK=1362   KO=2886  )
> response time 50th percentile                      13108 (OK=6141   KO=13188 )
> response time 75th percentile                      13569 (OK=7291   KO=13602 )
> response time 95th percentile                      14485 (OK=8188   KO=14491 )
> response time 99th percentile                      14920 (OK=8523   KO=14930 )
> mean requests/sec                                    125 (OK=6.188  KO=118.812)
---- Response Time Distribution ------------------------------------------------
> t < 800 ms                                             0 (  0%)
> 800 ms < t < 1200 ms                                   0 (  0%)
> t > 1200 ms                                           99 (  5%)
> failed                                              1901 ( 95%)
---- Errors --------------------------------------------------------------------
> j.n.ConnectException: Connection refused: no further informati   1901 (100,0%)
on: localhost/127.0.0.1:8080
================================================================================

Reports generated in 1s.
Please open the following file: C:\Users\NTNU-stud\gatling-2.3.0\results\wsmpread-1461761125877\index.html
Global: percentage of successful requests is greater than 95 : false
Press any key to continue . . . 
Gatling exited with: 0

This is my test.

package intel

import io.gatling.core.Predef._
import io.gatling.http.Predef._
import scala.concurrent.duration._

class WSMPRead extends Simulation {

  val httpConf = http
    .baseURL("http://localhost:8080/INTEL_Server")
    .acceptHeader("text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8")
    .acceptLanguageHeader("en-US,en;q=0.5")
    .acceptEncodingHeader("gzip, deflate")
    .userAgentHeader("Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:16.0) Gecko/20100101 Firefox/16.0")

  val headers_10 = Map(
    "Content-Type" -> "text/xml; charset=utf-8",
    "SOAPAction" -> """"REDACTED""""
  )

  val hiiuma_filter = """REDACTED"""

  val scn = scenario("WSMP Read: Empty result set")
    .exec(http("request_10")
      .post("/WSMPService")
      .headers(headers_10)
      .body(StringBody(hiiuma_filter))
      .check(
        regex("""REDACTED""").count.is(1)
      )
    )

  setUp(
    scn.inject(atOnceUsers(2000)).protocols(httpConf)
  ).assertions(
    global.successfulRequests.percent.greaterThan(95)
  )
}

This test is constructed to fail so that I can see that Gatling can crash the Jenkins test.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:9 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
slandellecommented, May 2, 2016

Cool, thanks!

Pro tip: press t when you’re in the code tab on github.

0reactions
michaelmcmillancommented, May 2, 2016

Woops, my bad! I’ll send you a patch.

Read more comments on GitHub >

github_iconTop Results From Across the Web

[MS-ERREF]: Win32 Error Codes - Microsoft Learn
In this article. All Win32 error codes MUST be in the range 0x0000 to 0xFFFF, although Win32 error codes can be used both...
Read more >
assert Macro, _assert, _wassert - Microsoft Learn
The assert macro prints a diagnostic message when expression evaluates to false (0) and calls abort to stop program execution. No action is ......
Read more >
Visual Studio 2019 version 16.11 Release Notes
Get the latest features, bug fixes, and support for Visual Studio 2019 v16.11. Download today.
Read more >
Add a build or release task in an extension - Azure DevOps
Cross -platform CLI for Azure DevOps to package your extensions. ... warningIssues.length, 0, "should have no warnings"); assert.equal(tr.
Read more >
C/C++ Assertions - Visual Studio (Windows) - Microsoft Learn
ASSERT (nM++ > 0); // Don't do this! Because the ASSERT expression is not evaluated in the Release version of your program, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found