Skip to content
Snippets Groups Projects
Commit 1b737550 authored by Éloïs's avatar Éloïs
Browse files

ci: fix integration tests execution

parent afe42deb
No related branches found
No related tags found
1 merge request!13ci: fix integration tests execution
......@@ -42,6 +42,8 @@ tests:
- if: '$CI_MERGE_REQUEST_ID ||$CI_COMMIT_BRANCH == "master" || $CI_COMMIT_BRANCH =~ /^release/'
- when: manual
stage: tests
variables:
DUNITER_INTEGRATION_TESTS_SPAWN_NODE_DURATION: "10"
script:
- cargo build
- cargo test
......@@ -63,7 +63,14 @@ pub async fn spawn_node() -> (Api, Client, Process) {
.spawn()
.expect("failed to spawn node"),
);
std::thread::sleep(std::time::Duration::from_secs(4));
let duration_secs = if let Ok(duration_string) =
std::env::var("DUNITER_INTEGRATION_TESTS_SPAWN_NODE_DURATION")
{
duration_string.parse().unwrap_or(4)
} else {
4
};
std::thread::sleep(std::time::Duration::from_secs(duration_secs));
let client = ClientBuilder::new()
.set_url(format!("ws://127.0.0.1:{}", ws_port))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment