Skip to content
This repository was archived by the owner on Dec 29, 2022. It is now read-only.

Commit e27de09

Browse files
authored
Merge pull request #1407 from ehuss/spurious-tests
Silence some flaky tests.
2 parents 7a83edc + a444169 commit e27de09

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

tests/client.rs

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1011,7 +1011,8 @@ fn client_find_definitions() {
10111011
let root_path = p.root();
10121012
let mut rls = p.spawn_rls_async();
10131013

1014-
let opts = json!({"settings": {"rust": {"racer_completion": false } } });
1014+
// FIXME: Without `all_targets=false`, this test will randomly fail.
1015+
let opts = json!({"settings": {"rust": {"racer_completion": false, "all_targets": false } } });
10151016
rls.request::<Initialize>(0, initialize_params_with_opts(root_path, opts));
10161017

10171018
rls.wait_for_indexing();
@@ -1398,7 +1399,9 @@ fn client_hover() {
13981399
let root_path = p.root();
13991400
let mut rls = p.spawn_rls_async();
14001401

1401-
rls.request::<Initialize>(0, initialize_params(root_path));
1402+
// FIXME: Without `all_targets=false`, this test will randomly fail.
1403+
let opts = json!({"settings": {"rust": { "all_targets": false } } });
1404+
rls.request::<Initialize>(0, initialize_params_with_opts(root_path, opts));
14021405

14031406
rls.wait_for_indexing();
14041407

@@ -1661,7 +1664,9 @@ fn client_highlight() {
16611664
let root_path = p.root();
16621665
let mut rls = p.spawn_rls_async();
16631666

1664-
rls.request::<Initialize>(0, initialize_params(root_path));
1667+
// FIXME: Without `all_targets=false`, this test will randomly fail.
1668+
let opts = json!({"settings": {"rust": { "all_targets": false } } });
1669+
rls.request::<Initialize>(0, initialize_params_with_opts(root_path, opts));
16651670

16661671
rls.wait_for_indexing();
16671672

@@ -1695,7 +1700,9 @@ fn client_rename() {
16951700
let root_path = p.root();
16961701
let mut rls = p.spawn_rls_async();
16971702

1698-
rls.request::<Initialize>(0, initialize_params(root_path));
1703+
// FIXME: Without `all_targets=false`, this test will randomly fail.
1704+
let opts = json!({"settings": {"rust": { "all_targets": false } } });
1705+
rls.request::<Initialize>(0, initialize_params_with_opts(root_path, opts));
16991706

17001707
rls.wait_for_indexing();
17011708

0 commit comments

Comments
 (0)