Skip to content
This repository has been archived by the owner on Jul 16, 2023. It is now read-only.

fix: improve context root included files calculation #862

Merged
merged 4 commits into from Jun 6, 2022

Conversation

incendial
Copy link
Member

@incendial incendial commented May 22, 2022

What is the purpose of this pull request? (put an "X" next to an item)

[ ] Documentation update
[X] Bug fix
[ ] New rule
[ ] Changes an existing rule
[ ] Add autofixing to a rule
[ ] Add a CLI option
[ ] Add something to the core
[ ] Other, please explain:

#850

@incendial incendial added this to the 5.0.0 milestone May 22, 2022
@incendial incendial requested a review from dkrutskikh May 22, 2022 10:11
@incendial incendial self-assigned this May 22, 2022
@github-actions
Copy link

github-actions bot commented May 22, 2022

Dart Code Metrics unused files report of dart_code_metrics. ✅

Summary

  • Scanned package folders: bin, example, lib
  • No unused files found! ✅

@github-actions
Copy link

github-actions bot commented May 22, 2022

Dart Code Metrics analyze report of dart_code_metrics. ✅

Summary

  • Scanned folders: bin, example, lib, test

  • Total scanned files: 426

  • Total lines of source code: 7455

  • Total classes: 291

  • Average Cyclomatic Number per line of code: 0.35

  • Average Source Lines of Code per method: 6

  • Total tech debt: 1310.0 hours

  • Found issues: 6 ⚠

@codecov
Copy link

codecov bot commented May 22, 2022

Codecov Report

Merging #862 (19a4a39) into master (e1ad7cd) will not change coverage.
The diff coverage is 100.00%.

❗ Current head 19a4a39 differs from pull request most recent head 17248e3. Consider uploading reports for the commit 17248e3 to get more accurate results

@@           Coverage Diff           @@
##           master     #862   +/-   ##
=======================================
  Coverage   87.27%   87.27%           
=======================================
  Files         280      280           
  Lines        5942     5942           
=======================================
  Hits         5186     5186           
  Misses        756      756           
Impacted Files Coverage Δ
lib/src/utils/analyzer_utils.dart 94.11% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 45c6894...17248e3. Read the comment docs.

@@ -36,7 +36,7 @@ Set<String> getFilePaths(
final newPath = normalize(join(rootFolder, path));
final rootPath = context.contextRoot.root.path;

return newPath == rootPath || rootPath.startsWith('$newPath/');
return newPath == rootPath || newPath.startsWith('$rootPath/');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@incendial please cover by unit test

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@incendial incendial requested a review from dkrutskikh June 5, 2022 17:12
@dkrutskikh dkrutskikh merged commit a43aab5 into master Jun 6, 2022
@dkrutskikh dkrutskikh deleted the fix-context-root-files-calculation branch June 6, 2022 18:54
@incendial incendial modified the milestones: 5.0.0, 4.16.0 Jun 16, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants