feat: add Huawei auth adapter
Add huawei auth adapter I refer to google auth adapter More information about huawei oauth: Huawei developer
New Pull Request Checklist
- [x] I am not disclosing a vulnerability.
- [x] I am creating this PR in reference to an issue.
Issue Description
Related issue: FILL_THIS_OUT
Approach
TODOs before merging
- [ ] Add tests
- [x] Add changes to documentation (guides, repository pages, in-code descriptions)
- [x] Add security check
- [ ] Add new Parse Error codes to Parse JS SDK
- [x] A changelog entry is created automatically using the pull request title (do not manually add a changelog entry)
Thanks for opening this pull request!
- ❌ Please edit your post and use the provided template when creating a new pull request. This helps everyone to understand your post better and asks for essential information to quicker review the pull request.
Codecov Report
Merging #7721 (6ccb356) into alpha (0c3feaa) will decrease coverage by
0.15%. The diff coverage is19.35%.
@@ Coverage Diff @@
## alpha #7721 +/- ##
==========================================
- Coverage 93.95% 93.79% -0.16%
==========================================
Files 183 184 +1
Lines 13660 13691 +31
==========================================
+ Hits 12834 12842 +8
- Misses 826 849 +23
| Impacted Files | Coverage Δ | |
|---|---|---|
| src/Adapters/Auth/huawei.js | 16.66% <16.66%> (ø) |
|
| src/Adapters/Auth/index.js | 93.65% <100.00%> (+0.10%) |
:arrow_up: |
| src/Adapters/Files/GridFSBucketAdapter.js | 80.32% <0.00%> (+0.81%) |
:arrow_up: |
| src/ParseServerRESTController.js | 98.50% <0.00%> (+1.49%) |
:arrow_up: |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing dataPowered by Codecov. Last update 410a1c7...6ccb356. Read the comment docs.
Do we need any tests here? Do other auth adapters have specific tests?
Do we need any tests here? Do other auth adapters have specific tests?
I only use Facebook and Huawei now. These two adapters are working well in common case.
- success
- expired token
- wrong token
- id is not matched
And my service uses very limited APIs
- Login
- Signup
- Link to other users
I only tested upper cases. If there isn't features to use auth adapter, I think it works well
I mean whether there are existing automated tests for other auth adapters, that we also need to add for this new Huawei adapter? See the /spec folder.