Skip to content

Commit

Permalink
fix: Update countries array in script.js
Browse files Browse the repository at this point in the history
  • Loading branch information
peterxcli committed Mar 16, 2024
1 parent d56d972 commit d51a0e6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions k6/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ let urlString = "http://127.0.0.1:8000/api/v1/ad";

const limits = [5, 10, 15];
const genders = ['M', 'F'];
const countries = ['TW', 'JP'];
const countries = ['US', 'TW', 'GB', 'AU', 'FR', 'DE'];
const platforms = ['android', 'ios', 'web'];

export default function () {
Expand All @@ -28,9 +28,9 @@ export default function () {
const gender = randomItem(genders);
const country = randomItem(countries);
const platform = randomItem(platforms);

for (let i = 0; i < 10; i++) {
// 用 new URL 效能會變差
// 用 new URL 效能會變差
http.get(
`${urlString}?limit=${limit}&offset=${i}&age=${age}&gender=${gender}&country=${country}&platform=${platform}`,
{
Expand Down

0 comments on commit d51a0e6

Please sign in to comment.