added tracker test
This commit is contained in:
26
tests/tracker.js
Normal file
26
tests/tracker.js
Normal file
@@ -0,0 +1,26 @@
|
||||
import http from "k6/http";
|
||||
import { check, sleep } from "k6";
|
||||
|
||||
export let options = {
|
||||
stages: [
|
||||
{ duration: "1m", target: 50 }, // 50 Benutzer
|
||||
{ duration: "1m", target: 100 }, // 100 Benutzer
|
||||
{ duration: "1m", target: 200 }, // 200 Benutzer
|
||||
{ duration: "1m", target: 400 }, // 400 Benutzer
|
||||
{ duration: "1m", target: 800 }, // 800 Benutzer
|
||||
{ duration: "1m", target: 1600 }, // 1600 Benutzer
|
||||
{ duration: "1m", target: 0 }, // runterfahren
|
||||
],
|
||||
thresholds: {
|
||||
http_req_duration: ["p(95)<800"], // 95% der Anfragen < 800ms
|
||||
http_req_failed: ["rate<0.05"], // Fehlerrate < 5%
|
||||
},
|
||||
};
|
||||
|
||||
export default function () {
|
||||
let res = http.get("https://dispatch.premiumag.de/tracker");
|
||||
check(res, {
|
||||
"Status ist 200": (r) => r.status === 200,
|
||||
});
|
||||
sleep(1); // simuliert Benutzerverhalten
|
||||
}
|
||||
Reference in New Issue
Block a user