-
-
Notifications
You must be signed in to change notification settings - Fork 473
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
Fixed the CI on api level 33 and reduce the CI timing. #3758
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0db5092
to
ff5b09d
Compare
…ause for a second to check if the delete dialog is displayed or not, and again we are waiting before clicking on it. The same issue for while clicking on the PlayStoreRestrictionDialogTest where we are first waiting for the dialog to visible and then waiting for clicking on it. So we have removed the second wait since this dialog is displaying in both test cases. * Improved the TopLevelDestinationTest. Because we were testing the drawer options fragments (Settings, Bookmarks etc) from the download screen and when we pressed the back button it came to the download screen and refreshed its data due to this our next functionality had to wait to finish this. Now we are testing all the navigation screens from the LocalLibraryScreen which makes this test case faster.
…ved bookmarks. * Refresh the data before checking the loaded data in DownloadTest. * Increasing the Retry count for loading data and downloading start to properly work with low internet connection.
… It was running in 2 minutes, but after this change, it now completes in 27 seconds.
…use, most of the time, the emulator does not have WiFi service. Running this test on this emulator is not worthwhile, as we are testing this code on WiFi.
…nally crashes during testing on API level 33 due to emulator lag on google_apis. The extensive data migration exacerbates the emulator's performance issues, leading to crashes during subsequent test processes. To address this issue, we have reduced the migration volume from 10K to 1K. Also, improved the ObjectBoxToLibkiwixMigratorTest.
…cumentId` test cases on API level 33. Since In this version, numerous security updates have been included, preventing us from modifying the default behavior of ContentResolver.
…ling due to `file_management_no_files` view not error. * Improved ObjectBoxToLibkiwixMigratorTest which sometime crashed due to process crashing.
… due to animation.
2ccd8fe
to
59cd4cf
Compare
… at startup which leads to the other test failures.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3758 +/- ##
============================================
+ Coverage 52.12% 53.07% +0.95%
- Complexity 1272 1292 +20
============================================
Files 292 292
Lines 10988 10988
Branches 1457 1457
============================================
+ Hits 5727 5832 +105
+ Misses 4312 4191 -121
- Partials 949 965 +16 ☔ View full report in Codecov by Sentry. |
@kelson42, @gouri-panda This PR is ready for review. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Fixes #2096
Improved the deleting of zim files in localibrary, since we already paused for a second to check if the delete dialog is displayed or not, and again we are waiting before clicking on it. The same issue for while clicking on the PlayStoreRestrictionDialogTest where we are first waiting for the dialog to visible and then waiting for clicking on it. So we have removed the second wait since this dialog is displaying in both test cases.
Improved the TopLevelDestinationTest. Because we were testing the drawer options fragments (Settings, Bookmarks, etc) from the download screen and when we pressed the back button it came to the download screen and refreshed its data due to this our next functionality had to wait to finish this. Now we are testing all the navigation screens from the LocalLibraryScreen which makes this test case faster.
Improved ObjectBoxToLibkiwixMigratorTest for clearing the previously saved bookmarks.
Improved the ObjectBoxToLibkiwixMigratorTest test case, as it occasionally crashes during testing on API level 33 due to emulator lag on google_apis. The extensive data migration exacerbates the emulator's performance issues, leading to crashes during subsequent test processes. To address this issue, we have reduced the migration volume from 10K to 1K. Also, improved the ObjectBoxToLibkiwixMigratorTest.
Refresh the data before checking the loaded data in DownloadTest.
Increasing the Retry count for loading data and downloading starts to properly work with a low internet connection.
Improved our ZimHostFragmentTest test to boost the test case speed It was running in 2 minutes, but after this change, it now completes in 27 seconds.
We are removing the ZimHostFragment test from the API level 33 because, most of the time, the emulator does not have WiFi service. Running this test on this emulator is not worthwhile, as we are testing this code on WiFi. /~https://github.com/kiwix/kiwix-android/actions/runs/8265444407/job/22611097563?pr=3747#step:6:1980.
Restricting the
testDocumentProviderContentQuery
andtestExtractDocumentId
test cases on API level 33. Since In this version, numerous security updates have been included, preventing us from modifying the default behavior of ContentResolver.Improved the SearchFragmentTest to make it fast.
Improved DownloadTest and InitialDownloadTest which sometimes fail due to the
file_management_no_files
view not error.Improved ObjectBoxToLibkiwixMigratorTest which sometimes crashed due to the process crashing.
Disabling animation on emulator since espresso sometimes giving error due to animation(It reduced the emulator boot time) /~https://github.com/kiwix/kiwix-android/actions/runs/8347337553/job/22846729987?pr=3758#step:5:47052.
We are not adding the sharing APK functionality in our test cases since after a failure the second run does not receive any test cases to run so that's why we are not introducing the sharing apk functionality. But our aim to make the CI faster is achieved since now CI is stable.
These changes makes the stable and faster. Before test cases were completed on API level 33(Android 13) in 18 Minutes and 57 seconds and by doing the above changes now it is completed in 15 minutes on the same API level so almost 4 minutes have been reduced.