Port dav calendar settings page to Vue.js#27008
Merged
skjnldsv merged 1 commit intonextcloud:masterfrom Jun 5, 2021
Merged
Conversation
bfbd5f3 to
1fc7aa1
Compare
This comment has been minimized.
This comment has been minimized.
tcitworld
reviewed
May 18, 2021
Contributor
|
Nice @francoisfreitag, Could you add some before/after screenshots ?
This is done by the community, so you don't have to think about it. |
artonge
requested changes
May 18, 2021
85b73de to
bd6bab7
Compare
Contributor
Author
|
Thanks for the reviews!
Changes
Pulled relevant bits in separate commits, will eventually squash all commits. I believe all feedback has been addressed and this PR is ready for another round of reviews. |
e6561eb to
53f624e
Compare
artonge
requested changes
May 31, 2021
827f684 to
5d186cc
Compare
Contributor
Author
Changes
|
tcitworld
approved these changes
May 31, 2021
Member
tcitworld
left a comment
There was a problem hiding this comment.
Apart from the js config global changes, LGTM
efc57e2 to
4cbd965
Compare
Contributor
Author
Changes
|
4cbd965 to
8d8b3fe
Compare
Contributor
Author
- Drop reliance on deprecated global jQuery object.
- Allow testing user interactions.
- Use newer technology stack.
---
Test user interactions with the groupware dav settings
Add infrastructure to test Vue components:
- Use recommended libraries:
- https://vuejs.org/v2/guide/testing.html#Recommendations
- Use jest-dom for robust assertions on the DOM state
- Use user-event to be more representative of user actions
- Code is transpiled by Jest, with the help of vue-jest.
Ignore test files for no-unpublished-import. Prevent ESLint from
flagging:
```
/home/runner/work/server/server/apps/dav/src/views/CalDavSettings.spec.js
Error: 1:24 error "@testing-library/vue" is not published node/no-unpublished-import
Error: 2:23 error "@testing-library/user-event" is not published node/no-unpublished-import
```
Signed-off-by: François Freitag <mail@franek.fr>
Contributor
Author
Changesdiff --git a/apps/dav/src/views/CalDavSettings.spec.js b/apps/dav/src/views/CalDavSettings.spec.js
index 6f25106bd6..3f9254a301 100644
--- a/apps/dav/src/views/CalDavSettings.spec.js
+++ b/apps/dav/src/views/CalDavSettings.spec.js
@@ -92,6 +92,7 @@ describe('CalDavSettings', () => {
return Promise.resolve()
})
await userEvent.click(generateBirthdayCalendar)
+ expect(generateBirthdayCalendar).toBeEnabled()
OCP.AppConfig.setValue.mockClear()
await userEvent.click(sendEventReminders) |
8d8b3fe to
70edda0
Compare
Member
I think he meant the js files changed outside of /dav/. But it's because of the babel config update. All good |
Contributor
Author
|
Awesome, thanks for the reviews and integrating! |
This file contains hidden or 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
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.


Add infrastructure to test Vue components:
Use recommended libraries:
Code is transpiled by Jest, with the help of vue-jest.