Skip to content

WRONG_INDENTATION: add more tests for extendedIndentAfterOperators#1401

Merged
0x6675636b796f75676974687562 merged 3 commits intomasterfrom
feature/andrey.shcheglov/indentation-unit-tests
Jun 27, 2022
Merged

WRONG_INDENTATION: add more tests for extendedIndentAfterOperators#1401
0x6675636b796f75676974687562 merged 3 commits intomasterfrom
feature/andrey.shcheglov/indentation-unit-tests

Conversation

@0x6675636b796f75676974687562
Copy link
Copy Markdown
Member

What's done:

Actions checklist

  • Added tests on checks
  • Added tests on fixers

@codecov
Copy link
Copy Markdown

codecov Bot commented Jun 24, 2022

Codecov Report

Merging #1401 (8276dcf) into master (0351f52) will increase coverage by 0.01%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##             master    #1401      +/-   ##
============================================
+ Coverage     83.39%   83.40%   +0.01%     
  Complexity     2538     2538              
============================================
  Files           106      106              
  Lines          7623     7623              
  Branches       2089     2089              
============================================
+ Hits           6357     6358       +1     
  Misses          375      375              
+ Partials        891      890       -1     
Flag Coverage Δ
unittests 83.40% <ø> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
.../cqfn/diktat/ruleset/utils/indentation/Checkers.kt 81.19% <0.00%> (+0.85%) ⬆️

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 0351f52...8276dcf. Read the comment docs.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 24, 2022

JUnit Tests (macOS, EnricoMi/publish-unit-test-result-action@v1)

1 270 tests   1 255 ✔️  8m 32s ⏱️
   157 suites       15 💤
   157 files           0

Results for commit 9e8527f.

♻️ This comment has been updated with latest results.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 24, 2022

JUnit Tests (Windows, EnricoMi/publish-unit-test-result-action@v1)

1 270 tests   1 255 ✔️  13m 31s ⏱️
   157 suites       15 💤
   157 files           0

Results for commit 9e8527f.

♻️ This comment has been updated with latest results.

Copy link
Copy Markdown
Member

@orchestr7 orchestr7 left a comment

Choose a reason for hiding this comment

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

lgtm, but please remove at least some complexity with annotations

### What's done:

 * Tests for expressions wrapped on an operator have been added.
 * Both cases (when `extendedIndentAfterOperators` is `true` and `false`) are
   tested.
 * Both binary operators and functions are tested.
 * Related: #1340
### What's done:

 * Test resources extracted into a separate class so that DeteKT remains quiet.
 * Reformatted test code so that DiKTat remains quiet.
### What's done:

 * Code cleaned up.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

WRONG_INDENTATION: extendedIndentAfterOperators ignored if lines are wrapped before a binary operator or an infix function

2 participants