Skip to content

Commit 75feb4a

Browse files
captbaritonefacebook-github-bot
authored andcommitted
Await async mutex for test isolation
Differential Revision: D50141752
1 parent fad7f38 commit 75feb4a

File tree

1 file changed

+3
-2
lines changed
  • compiler/crates/fixture-tests/src

1 file changed

+3
-2
lines changed

compiler/crates/fixture-tests/src/lib.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,10 @@ pub async fn test_fixture<T, U, V>(
107107
let expect_ok = !input.contains("expected-to-throw");
108108
let actual_result: Result<U, V>;
109109
{
110-
let _guard = LOCK.lock();
111-
env::set_var("NO_COLOR", "1");
110+
let _guard = LOCK.lock().await;
111+
colored::control::set_override(false);
112112
actual_result = transform(&fixture).await;
113+
colored::control::unset_override();
113114
}
114115

115116
let actual = match &actual_result {

0 commit comments

Comments
 (0)