Commit Graph

148 Commits

Author SHA1 Message Date
Jonas Schievink 93b62dbe85 Improve docs generation assist 2022-05-18 18:05:21 +02:00
Lukas Wirth 9fe1b24736 Update config usage in slow tests 2022-05-01 19:57:09 +02:00
Peh aade31943f delete another swap file 2022-05-01 10:48:58 +00:00
Peh 14c30b7979 update crates names in slow-tests/tidy.rs 2022-05-01 10:48:58 +00:00
Deadbeef 8b60bf6764 Update CI for Rust bors 2022-04-13 16:55:10 +02:00
Lukas Wirth 3a847eacc8 fix: Show the path to be created in the unresolved-module fix label 2022-04-04 16:04:09 +02:00
Laurențiu Nicola 86b1ef9ab2 Bump deps 2022-03-17 19:24:37 +02:00
Aleksey Kladov 56e43c34e7 ⬆️ xshell 2022-03-14 14:57:24 +00:00
Matthias Krüger 56e4ea59d9 more clippy fixes:
clippy::match_like_matches_macro
clippy::to_string_in_format_args
clippy::single_char_add_str
clippy::filter_map_identity
clippy::clone_on_copy
clippy::useless_format
clippy::unused_unit
2022-03-12 16:50:49 +01:00
Matthias Krüger 1f70886b15 fix clippy::single_char_pattern 2022-03-12 16:50:49 +01:00
Lukas Wirth a9dd606387 fix: Show what file paths were expected for unresolved modules 2022-03-11 17:08:30 +01:00
Lukas Wirth 93b09ca067 Update tidy ignore list 2022-03-06 19:18:40 +01:00
Jonas Schievink 3c51aaf065 Fix merge commit check for git 2.35 2022-01-26 19:10:39 +01:00
Lukas Wirth dd20a6f701 feat: poke user when supplying faulty configurations 2022-01-06 14:24:19 +01:00
Aleksey Kladov a1c33c2e1a test: force client-side watching
The direct reason for this is to fix CI on windows, which seems to fail
for some reason after we fixed the watcher-selection logic which (I
think) changed the tests behavior to use notify rather than client.

But this patch seems to make sense in general -- file watching is
notoriously finicky, so controlling it explicitly leads to less fragile
tests.
2022-01-01 19:16:25 +03:00
Aleksey Kladov 0d1e23e968 better error message 2022-01-01 18:55:53 +03:00
Laurențiu Nicola 89a1256f9a Bump most deps 2021-12-04 15:08:37 +02:00
Lukas Wirth f72512f1c6 Simplify 2021-11-17 21:02:33 +01:00
Lukas Wirth 91bbc55eed Check for derive attributes by item path, not derive identifier 2021-11-17 20:46:57 +01:00
Laurențiu Nicola 139bf9b4e1 Use array into_iter in more places 2021-11-04 07:51:20 +02:00
Lukas Wirth 722489e3ff Remove filtered completion list usage in completion tests 2021-10-27 16:53:39 +02:00
Laurențiu Nicola f0ad6fa68b Revert edition change in test 2021-10-24 14:52:42 +03:00
Laurențiu Nicola ca44b6892e Use array IntoIter 2021-10-22 09:23:29 +03:00
Lukas Wirth 1294bfce86 Migrate to edition 2021 2021-10-21 20:10:40 +02:00
bors[bot] d9080addf9 Merge #10562
10562: fix: Fix clippy attribute completions always prefixing inserting `clippy::` r=Veykril a=Veykril

Fixes https://github.com/rust-analyzer/rust-analyzer/issues/7144

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-10-17 11:30:49 +00:00
Lukas Wirth 99906baa17 Fix clippy attribute completions always prefixing with clippy:: 2021-10-17 13:07:49 +02:00
Milo 35e5daacc3 more clippy fixes 2021-10-16 12:32:55 +01:00
bors[bot] c5354877c9 Merge #10503
10503: Only include targets of packages that are workspace members r=Veykril a=bcully

CargoWorkspace's package list includes packages that are path
dependencies, even if those packages aren't actually members of the
cargo workspace. As a result, rust-analyzer's runnable finder, which
returns the target from the first workspace that has a matching package,
may select the wrong working directory, causing runnables to fail, e.g.,
```
error: package `root` cannot be tested because it requires dev-dependencies and is not a member of the workspace
```

To fix this, we filter out packages that aren't members of the workspace
when searching for targets.

Fixes #7764

Co-authored-by: Brendan Cully <brendan@cully.org>
2021-10-14 11:42:53 +00:00
Lukas Wirth 22f471d81f Update tidy ignore path 2021-10-12 09:47:21 +02:00
Brendan Cully 841d4f9dad Only include targets of packages that are workspace members
CargoWorkspace's package list includes packages that are path
dependencies, even if those packages aren't actually members of the
cargo workspace. As a result, rust-analyzer's runnable finder, which
returns the target from the first workspace that has a matching package,
may select the wrong working directory, causing runnables to fail, e.g.,
```
error: package `root` cannot be tested because it requires dev-dependencies and is not a member of the workspace
```

To fix this, we filter out packages that aren't members of the workspace
when searching for targets.

Fixes #7764
2021-10-11 18:28:05 -07:00
bors[bot] eb17e90eba Merge #10105
10105: RfC: Use `todo!()` instead of `()` for missing fields r=jonas-schievink a=jo-so

Most commonly a field of a struct can be initialized with its default value than an empty tuple.

Co-authored-by: Jörg Sommer <joerg@jo-so.de>
2021-09-24 15:12:17 +00:00
Lukas Wirth e60f3d265f Split the hover module up 2021-09-23 20:36:15 +02:00
Lukas Wirth 8b2be8572f Rename some assists 2021-09-21 00:54:09 +02:00
Lukas Wirth dfb94d09d4 Exclude test file from rust tidy check 2021-09-14 00:21:16 +02:00
Lukas Wirth edc915fbb6 Add proc-macro fixture directive 2021-09-13 18:37:50 +02:00
Jörg Sommer c87b860d3d Use todo!() instead of () for missing fields
The generated code with `()` doesn't compile in most of the cases. To signal
the developer there's something to do, fill in `todo!()`.

Because the file *missing_fields.rs* contains the string `todo!()` it needs
an exception for the test *check_todo*.
2021-09-09 18:04:50 +02:00
Dezhi Wu ba0947dded switch log crate to tracing 2021-08-30 15:11:42 +08:00
Yoshua Wuyts 326890753c implement feedback from review 2021-08-10 12:21:48 +02:00
Yoshua Wuyts d6b788a9ee Add trait codegen to add_missing_impl_members assist 2021-08-10 10:27:52 +02:00
Yoshua Wuyts 5a3c3a029c exclude files from tidy check 2021-08-08 18:44:54 +02:00
Aleksey Kladov b97eec8c0e fix tests 2021-07-19 16:38:36 +03:00
Lukas Wirth d837a5d5a7 Show test mod runnable in outline modules 2021-07-14 11:30:51 +02:00
Aleksey Kladov 90e27d6289 internal: make xtask lighter
Moving tests to `rust-analyzer` crate allows removing walkdir dependency
from `xtask`. It does seem more reasonable to keep tidy tests outside of
the "build system" and closer to other integration tests.
2021-07-04 12:47:56 +03:00
Aleksey Kladov 58d2ece88a internal: overhaul code generation
* Keep codegen adjacent to the relevant crates.
* Remove codgen deps from xtask, speeding-up from-source installation.

This regresses the release process a bit, as it now needs to run the
tests (and, by extension, compile the code).
2021-07-03 22:11:03 +03:00
Aleksey Kladov f521e41853 internal: introduce minicore -- a subset of libcore for testing 2021-06-15 21:03:08 +03:00
Maan2003 c9b4ac5be4 clippy::redudant_borrow 2021-06-13 09:24:16 +05:30
Aleksey Kladov 459b0332d3 internal: use more evocative test folder name 2021-05-17 19:01:54 +03:00
Aleksey Kladov 41510f437e minor: adjust config name 2021-05-17 18:37:06 +03:00
John Renner 7ae3967e57 Formatting and docs 2021-05-10 13:34:09 -07:00
John Renner c3ba1f14fa Allow semantic tokens for strings to be disabled 2021-05-10 13:09:38 -07:00