Summary: | Cypress videos and screenshots should be .gitignored | ||
---|---|---|---|
Product: | Koha | Reporter: | Pedro Amorim <pedro.amorim> |
Component: | Architecture, internals, and plumbing | Assignee: | Pedro Amorim <pedro.amorim> |
Status: | Pushed to main --- | QA Contact: | Katrin Fischer <katrin.fischer> |
Severity: | trivial | ||
Priority: | P5 - low | CC: | david, martin.renvoize |
Version: | Main | Keywords: | additional_work_needed |
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Trivial patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: |
This updates .gitignore so that the directories for any screenshots and videos created by cypress tests are ignored by git. The directories created are:
- t/cypress/screenshots/
- t/cypress/videos/
|
Version(s) released in: |
24.11.00
|
Circulation function: | |||
Attachments: |
Bug 37493: [DONT PUSH] Test only
Bug 37493: Update .gitignore Bug 37493: [DONT PUSH] Test only - Force test fail Bug 37493: Update .gitignore Bug 37493: [DONT PUSH] Test only - Force test fail Bug 37493: Update .gitignore |
Description
Pedro Amorim
2024-07-26 13:19:20 UTC
Created attachment 169705 [details] [review] Bug 37493: [DONT PUSH] Test only Apply this patch only, run: 1) cypress run --spec "t/cypress/integration/AdditionalFields_spec.ts" 2) run `git status`. Notice t/cypress/screenshots/ and t/cypress/videos/ show 3) Apply 2nd patch. Repeat 2). Notice its empty Created attachment 169706 [details] [review] Bug 37493: Update .gitignore Add t/cypress/screenshots/ Add t/cypress/videos/ Created attachment 169708 [details] [review] Bug 37493: [DONT PUSH] Test only - Force test fail Apply this patch only, run: 1) cypress run --spec "t/cypress/integration/flatpickr_spec.ts" 2) run `git status`. Notice t/cypress/screenshots/ and t/cypress/videos/ show 3) Apply 2nd patch. Repeat 2). Notice its empty Created attachment 169709 [details] [review] Bug 37493: Update .gitignore Add t/cypress/screenshots/ Add t/cypress/videos/ Created attachment 169794 [details] [review] Bug 37493: [DONT PUSH] Test only - Force test fail Apply this patch only, run: 1) cypress run --spec "t/cypress/integration/flatpickr_spec.ts" 2) run `git status`. Notice t/cypress/screenshots/ and t/cypress/videos/ show 3) Apply 2nd patch. Repeat 2). Notice its empty Signed-off-by: David Nind <david@davidnind.com> Created attachment 169795 [details] [review] Bug 37493: Update .gitignore Add t/cypress/screenshots/ Add t/cypress/videos/ Signed-off-by: David Nind <david@davidnind.com> If these files are ignored, won't the space the screenshots and videos take up git* a little large after a while. Or are these removed automatically at some stage when the tests are all successfully run? * A bad pun! 8-) QA'd by RM. (In reply to David Nind from comment #7) > If these files are ignored, won't the space the screenshots and videos take > up git* a little large after a while. Or are these removed automatically at > some stage when the tests are all successfully run? > > * A bad pun! 8-) Hm, good question. I guess you will no longer see this files in the git status, so they might be easy to miss. Pedro, can you please comment? Forgot to remove from local branch - pushed to main for now. Waiting for the reply to decide if we want to keep or not. (In reply to David Nind from comment #7) > If these files are ignored, won't the space the screenshots and videos take > up git* a little large after a while. Or are these removed automatically at > some stage when the tests are all successfully run? > > * A bad pun! 8-) I don't believe these will be removed after a while. This was only a tiny enhancement to prevent me from adding videos to commits as I've done in the past, but I'm happy to have this dropped and ignore this locally. (In reply to Katrin Fischer from comment #10) > Forgot to remove from local branch - pushed to main for now. > Waiting for the reply to decide if we want to keep or not. Please note that you have pushed the [DONT PUSH] patch. That'll cause cypress tests to fail: https://github.com/Koha-Community/Koha/commit/0d69fc60904ec6ad95863977d8cdec35e29047bf Mentioning this to make sure both patches are dropped. Guess... this was not my best day. I'll revert the DONT PUSH at least right now. (In reply to Katrin Fischer from comment #12) > Guess... this was not my best day. > I'll revert the DONT PUSH at least right now. Done. Perhaps we add a QA hook to check that files in that space are not included in any commits instead? |