-
Notifications
You must be signed in to change notification settings - Fork 499
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
Fix #3360: Platform Parameter Dagger Module and Constants File [BLOCKED on #3323] #3361
Conversation
… PlatformParameter Constants file to store any constants related to Platform Parameters
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is interesting since I don't think we want to hard-code any example parameters into this module, but we don't yet have features that are using this module quite yet. For similar reasons we also don't have a means of testing this module.
Overall the PR looks pretty good but I'm not sure if we want to check this in with fake parameters. I'll defer to @vinitamurthi on her thoughts about how we might update this but I don't see anything else major in this PR -- nice job!
Only additional comment is to mentions which files or lines of code are newly-added in this PR so reviewers don't re-review code from the past PRs.
domain/src/main/java/org/oppia/android/domain/platformparameter/PlatformParameterModule.kt
Outdated
Show resolved
Hide resolved
domain/src/main/java/org/oppia/android/domain/platformparameter/PlatformParameterModule.kt
Outdated
Show resolved
Hide resolved
utility/src/main/java/org/oppia/android/util/platformparameter/PlatformParameter.kt
Outdated
Show resolved
Hide resolved
I have added these Example Parameters just to show how are we trying to provide the parameters. We can remove them once we can actually add a PlatformParameter (which will happen once we reach the end of Milestone 1) I will write the tests the tests now, just wanted to have first review over the kind of changes Edited the description to highlight the newly added files. |
I understand why we have the examples parameters but it seems odd to check in code that's not used. That said, I do agree that it would still be best to include these examples largely as a means of testing the module especially since it's using the map in the earlier PR and we probably want to check that it's handled correctly. Please add the test file, and I also recommend being explicit that the parameters in the modules are only examples and not used for actual parameters yet. Maybe changing the names to |
domain/src/test/java/org/oppia/android/domain/platformparameter/PlatformParameterModuleTest.kt
Outdated
Show resolved
Hide resolved
@jcqli @vinitamurthi PTAL at the PlatformParameterModuleTest file. If this approach looks good to you then we can have more test cases. |
LGTM, recommend naming "FakePlatformParameterModule" to "TestPlatformParameterModule". |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Approving only for code-owner file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
@Arjupta a couple of things:
|
@anandwana001 @jcqli , if the changes look good to you, can you please approve the PR? The merge is currently blocked on your reviews |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code owners file LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Hi @Arjupta, this PR is ready to be merged. Please address any remaining comments prior to merging, and feel free to merge this PR once the CI checks pass and you're happy with it. Thanks! |
Explanation
Fixes #3360
This PR introduce a new Dagger Module which will provide the PlatformParameters and a Parameter Constants file to store the annotations, names, default values at one place.
Note - This PR containes the changes from PR1.2 and PR1.2 which were made from the fork of Oppia Repository, This PR is made directly from Oppia-Android repository in order to help us with Stacking PRs. Both of the previous PRs were almost reviewed so instead of reopening them we will copy the changes made in them here in order to develop over those changes. Any further change in these two PRs will be included here also (manually copy pasted) till the time those PRs are merged. Any further PR that will be made afterwards, will be stacked based on this PR (if needed).
/cc @Sarthak2601
Change associated with this PR -
Rest of the files are from previous two PRs.
Checklist