Skip to content

Commit

Permalink
fix: increase Windows e2e timeout and print body
Browse files Browse the repository at this point in the history
  • Loading branch information
Angelmmiguel committed May 23, 2023
1 parent 2791a36 commit 75fb206
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
- os: macos-latest
e2e_time: 20
- os: windows-latest
e2e_time: 30
e2e_time: 60
runs-on: ${{ matrix.os }}
env:
E2E_WAITING_TIME: ${{ matrix.e2e_time }}
Expand Down
26 changes: 14 additions & 12 deletions tests/e2e.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ mod test {
}
};

println!("Body content: {body}");

// Test
assert!(body.contains(expected_text));

Expand All @@ -88,6 +90,18 @@ mod test {
};

let tests = [
(
"rust-basic",
global_timeout.unwrap_or(10),
"http://localhost:8080/basic",
"This page was generated by a Wasm module built from Rust",
),
(
"rust-kv",
global_timeout.unwrap_or(10),
"http://localhost:8080/kv",
"Counter: 0",
),
(
"js-basic",
global_timeout.unwrap_or(10),
Expand All @@ -106,18 +120,6 @@ mod test {
"http://localhost:8080/thisisatest",
"thisisatest",
),
(
"rust-basic",
global_timeout.unwrap_or(10),
"http://localhost:8080/basic",
"This page was generated by a Wasm module built from Rust",
),
(
"rust-kv",
global_timeout.unwrap_or(10),
"http://localhost:8080/kv",
"Counter: 0",
),
];

for (example, waiting_seconds, url, expected_text) in tests {
Expand Down

0 comments on commit 75fb206

Please sign in to comment.