Created
January 12, 2013 12:53
-
-
Save anonymous/4517979 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package local | |
import com.excilys.ebi.gatling.core.Predef._ | |
import com.excilys.ebi.gatling.http.Predef._ | |
import com.excilys.ebi.gatling.jdbc.Predef._ | |
import com.excilys.ebi.gatling.http.Headers.Names._ | |
import akka.util.duration._ | |
import bootstrap._ | |
import assertions._ | |
import java.net.URLEncoder | |
class RecordedAdSpotSimulationProdTest extends Simulation { | |
val httpConf = httpConfig | |
.baseURL("http://localhost.local:8070") | |
.acceptHeader("*/*") | |
.acceptEncodingHeader("gzip, deflate") | |
.acceptLanguageHeader("en-US,en;q=0.5") | |
.userAgentHeader("Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:18.0) Gecko/20100101 Firefox/18.0") | |
val headers_ps = Map( | |
"Connection" -> "keep-alive" | |
) | |
val chain = exec(http("affilliate html") | |
.get("http://localhost.local/index.html") | |
.check(status.is(200)) | |
) | |
.pause(90 milliseconds) | |
.exec(http("ps.jsp") | |
.get("http://localhost.local/ps.jsp") | |
.headers(headers_ps) | |
) | |
val scn = scenario("stress test") | |
.group("full html"){exec(chain)} | |
setUp(scn.users(2000).ramp(57).protocolConfig(httpConf)) | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment