Skip to content
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

test: Add Unit tests for the ListLanguagesAction.java class #663

Merged
merged 5 commits into from
Oct 12, 2023

Conversation

Sweetdevil144
Copy link
Contributor

Fix #658 .

  • Added Unit tests for file ListLanguagesAction.java
  • Current code coverage = 65% for the file.
  • Code coverage can be further improved by contributors further on this month.

Sweetdevil144 and others added 3 commits October 11, 2023 10:40
Added more Unit tests to FileUtils class
Improved code coverage from 70% to 95%
Added Unit tests for the ListLanguagesAction.java class
@codecov
Copy link

codecov bot commented Oct 11, 2023

Codecov Report

Merging #663 (7937194) into main (f2852d3) will increase coverage by 0.48%.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##               main     #663      +/-   ##
============================================
+ Coverage     63.04%   63.52%   +0.48%     
- Complexity     1362     1376      +14     
============================================
  Files           209      209              
  Lines          5643     5643              
  Branches        849      849              
============================================
+ Hits           3557     3584      +27     
+ Misses         1631     1601      -30     
- Partials        455      458       +3     
Files Coverage Δ
...n/java/com/crowdin/cli/client/LanguageMapping.java 95.00% <100.00%> (ø)

... and 1 file with indirect coverage changes

@andrii-bodnar
Copy link
Member

@Sweetdevil144 thank you!

Could you please also include tests to cover the 56-58 and 70-83 lines?

https://app.codecov.io/gh/crowdin/crowdin-cli/pull/663/blob/src/main/java/com/crowdin/cli/commands/actions/ListLanguagesAction.java

Screenshot 2023-10-12 at 09 20 30

@andrii-bodnar andrii-bodnar added hacktoberfest This issue welcomes contributions for Hacktoberfest tests labels Oct 12, 2023
@Sweetdevil144
Copy link
Contributor Author

Okay sure. Doing it now!!

@Sweetdevil144
Copy link
Contributor Author

@andrii-bodnar Increased the code coverage

Copy link
Member

@andrii-bodnar andrii-bodnar left a comment

Choose a reason for hiding this comment

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

@Sweetdevil144 thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hacktoberfest This issue welcomes contributions for Hacktoberfest hacktoberfest-accepted tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Unit tests for the ListLanguagesAction.java class
2 participants