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

App localization test was created for increasing coverage and reliability #1619

Merged

Conversation

Kushalrock
Copy link
Contributor

What kind of change does this PR introduce?
A new test to check app localization utils was introduced

Issue Number
Closes #1530

Have you read the [contributing guide]?
Yes

Summary
As mentioned in #1217 talawa mobile app needs to be very reliable and is slowly inching toward complete test coverage. This issue solves #1530 and adds tests for the app localization file in utils folder.

Screenshots Supporting the PR
Screenshot (429)

@codecov
Copy link

codecov bot commented Mar 5, 2023

Codecov Report

Merging #1619 (06a53dd) into develop (1f15ddd) will increase coverage by 0.01%.
The diff coverage is n/a.

@@             Coverage Diff             @@
##           develop    #1619      +/-   ##
===========================================
+ Coverage    80.61%   80.62%   +0.01%     
===========================================
  Files          144      144              
  Lines         7272     7272              
===========================================
+ Hits          5862     5863       +1     
+ Misses        1410     1409       -1     
Impacted Files Coverage Δ
lib/utils/app_localization.dart 100.00% <0.00%> (+3.84%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@Cioppolo14 Cioppolo14 self-requested a review March 5, 2023 13:46
@Cioppolo14
Copy link
Contributor

Cioppolo14 commented Mar 5, 2023

@Kushalrock Please refer to the PR_GUIDELINES.md document in the root folder of the repo. It tells you how to automatically close your issue when the PR is merged.

@Kushalrock
Copy link
Contributor Author

@Kushalrock Please refer to the PR_GUIDELINES.md document in the root folder of the repo. It tells you how to automatically close your issue when the PR is merged.

Thank you @Cioppolo14. I have already linked the pull request to the issue such that if PR merges issue will get closed. Anything else that I need to add?

@Cioppolo14
Copy link
Contributor

@Kushalrock My apologies, I misunderstood something. I will assign reviewers.

@Cioppolo14 Cioppolo14 requested review from noman2002 and TheHazeEffect and removed request for Cioppolo14 March 5, 2023 14:26
@palisadoes palisadoes requested a review from CyberWake March 5, 2023 23:41
Copy link
Member

@CyberWake CyberWake left a comment

Choose a reason for hiding this comment

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

@Kushalrock I think we should also have test written for the usecase where initial language was x(supported language) which later on was switched to y(supported language)

TheHazeEffect
TheHazeEffect previously approved these changes Mar 6, 2023
@Kushalrock
Copy link
Contributor Author

Kushalrock commented Mar 6, 2023

@CyberWake I have done what you asked you can go ahead and check. Thank you for your review. I have uploaded image for reference it also checks whether or not the thing works after locale change

image

@Kushalrock Kushalrock requested review from CyberWake and TheHazeEffect and removed request for noman2002, CyberWake and TheHazeEffect March 6, 2023 08:35
@Kushalrock
Copy link
Contributor Author

@CyberWake any update?

@palisadoes palisadoes requested a review from tonythegr8 March 7, 2023 13:43
noman2002
noman2002 previously approved these changes Mar 7, 2023
Copy link
Member

@noman2002 noman2002 left a comment

Choose a reason for hiding this comment

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

Looks Good to me

@palisadoes
Copy link
Contributor

We have a new check in place. All Talawa mobile app methods, classes and functions need to have suitable comments. Please refer to this issue as reference for what is now required. The aim is to help us improve the quality of our automated documentation on docs.talawa.io.

To fix this issue:

  1. You will be required to remove a line containing ignore_for_file
  2. After doing so you'll be requested to update the comments appropriately

We have also tried to make the documentation step automatically update your IDE with a custom Linter. If you have any comments, please contact @literalEval who worked on this code.

@CyberWake
Copy link
Member

@Kushalrock please look for the code coverage why it went low by 0.05%. Resolving so would allow us to proceed to reviewing and merge upon success.

@Kushalrock
Copy link
Contributor Author

Kushalrock commented Mar 9, 2023

@CyberWake I will look into that also what is this linting issue that I got commented by Peter. Do I have to do anything about that. Also I have not made any deletion so how can I reduce the code coverage?

@Kushalrock
Copy link
Contributor Author

@CyberWake Merged the branch with latest pull now. Can you please check and approve.

@literalEval
Copy link
Member

@Kushalrock please add /// None after the /// params line. Don't leave it blank. Thanks.

@Kushalrock
Copy link
Contributor Author

@literalEval Done.

@literalEval
Copy link
Member

@Kushalrock and remove the extra /// at last :)

@Kushalrock
Copy link
Contributor Author

@literalEval Done again 😅🤣

@literalEval
Copy link
Member

:) Thanks.

@Kushalrock
Copy link
Contributor Author

@literalEval Can something be developed that will help developers with documentation like some kind of VS Code plugin which can make use of VS code Quick Fix to complete documentation errors or atleast provide a template.

@literalEval
Copy link
Member

@Kushalrock that's exactly what we have done with talawa_lint. Please read my pinned message in #talawa Slack channel to get more information about this. Alternatively, please re-read INSTALLATION.md and CONTRIBUTING.md

@Kushalrock
Copy link
Contributor Author

@literalEval Thanks I just skimmed through linting section. Shouldn't have done that😅

@literalEval
Copy link
Member

literalEval commented Mar 9, 2023

No worries. I have also written a proper documentation for our custom lint system and its merge is pending in talawa-doc. Once merged, I'll inform everyone with the page's link :)

@palisadoes palisadoes merged commit 10b75aa into PalisadoesFoundation:develop Mar 9, 2023
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.

Test app_localization.dart
7 participants