Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Оптимизация механизма запуска тестов. #3388
base: develop
Are you sure you want to change the base?
Оптимизация механизма запуска тестов. #3388
Changes from 6 commits
5bfc959
5df4864
db12e51
c05d94c
e1d0cb6
0c51300
393ae5f
11377b2
30ff5fe
35a9dd5
45bd658
c0cdba9
c515628
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Улучшение метода
isInside
для корректной проверки вложенностиИспользование
URI.relativize()
может давать неверные результаты при работе с URI, содержащими разные схемы или хосты. Рекомендуется использоватьPaths
для проверки вложенности путей.Предлагаю изменить метод следующим образом:
Check notice on line 55 in src/main/java/com/github/_1c_syntax/bsl/languageserver/codelenses/RunAllTestsCodeLensSupplier.java
GitHub Actions / Qodana for JVM
Non recommended 'field' injections
Check notice
Code scanning / QDJVM
Non recommended 'field' injections Note
Check notice on line 62 in src/main/java/com/github/_1c_syntax/bsl/languageserver/codelenses/RunTestCodeLensSupplier.java
GitHub Actions / Qodana for JVM
Non recommended 'field' injections
Check notice
Code scanning / QDJVM
Non recommended 'field' injections Note
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Не нравится цикл в цикле. Не будет проблемой?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Количество аннотаций на метод в тестовых сорцах достаточно маленькое, в среднем чуть больше одной. Так что не думаю, что эти будет большой проблемой.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
переделано на Set.contains
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Строковую константу по хорошему лучше явно вынести. Она точно никогда-никогда не может быть двуязычной?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Текущие тестовые фреймворки не поддерживают других аннотаций. Думаешь в конфиг унести и сразу добавить оба языка?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Угу. Текущий хардкод выглядит немного неаккуратно
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
переделал на конфиг