mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-06-17 08:06:38 +00:00
Fix cargo test
run on CI
`cargo test` run all tests in one process. As such, `set_global_default` would fail on the second call. Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
ffe47d30c6
commit
962a7d057c
1 changed files with 2 additions and 1 deletions
|
@ -149,6 +149,7 @@ impl GhApiClient {
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
async fn do_fetch<T, U, GraphQLFn, RestfulFn, GraphQLFut, RestfulFut>(
|
async fn do_fetch<T, U, GraphQLFn, RestfulFn, GraphQLFut, RestfulFut>(
|
||||||
&self,
|
&self,
|
||||||
graphql_func: GraphQLFn,
|
graphql_func: GraphQLFn,
|
||||||
|
@ -345,7 +346,7 @@ mod test {
|
||||||
.finish();
|
.finish();
|
||||||
|
|
||||||
// Setup global subscriber
|
// Setup global subscriber
|
||||||
set_global_default(subscriber).unwrap();
|
let _ = set_global_default(subscriber);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Mark this as an async fn so that you won't accidentally use it in
|
/// Mark this as an async fn so that you won't accidentally use it in
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue