29 Commits

Author SHA1 Message Date
Christophe Bliard 27a677e0c5 Output Browser logs on failure for Cuprite Capybara driver 2026-02-06 15:47:31 +01:00
Eric Schubert 6435804192 [chore] use explicit swiftshader GL for chrome testing
Swiftshader is a software based fallback for WebGL context used in
Chrome without GPU access - e.g. in headless browsers for testing, or
containerized selenium browsers, like in our docker dev setup. The
automatic fallback to Swiftshader was disabled in January 2026, causing
any test using a WebGL context to fail.
See https://chromium.googlesource.com/chromium/src/+/refs/heads/main/docs/gpu/swiftshader.md
To fix that, we enabled the unsafe fallback now manually for testing
contexts.
2026-01-27 14:48:12 +01:00
Jan Sandbrink 0ab7423c9a Fix running Cuprite tests in Docker
This ultimatively seems to be a bug in Ferrum or an incompatibility
between Ferrum and browserless. I understand that the setting defines
whether a single or multiple web socket connections are used to communicate
with the browser, but apart from that I don't understand well what the actual
issue is.
2025-10-14 07:53:20 +02:00
Jan Sandbrink a9babeaaba Upgrade to latest available browserless image
Browserless migrated away from Docker Hub and the latest versions
are now available on GitHub's Container Registry.
2025-10-10 15:34:17 +02:00
Henriette Darge f496da2aad Merge release/16.0 into dev 2025-05-16 14:56:25 +02:00
Christophe Bliard 01d8ede6a4 [62341] Correctly convert dates when timezone is negative in datepicker
flatpickr is using local dates at midnight internally and in its
callback functions. In datepicker component and stimulus controller we
are using UTC dates at midnight.

And the timezone service is assuming local time when converting to iso dates.

Fixed it by explcitly converting from utc date to iso string, and using
iso date strings when setting flatpickr dates, avoiding any issues.

It could be a good idea to use iso date strings everywhere as much as
possible instead of always jumping back and forth from dates to iso
string.
2025-03-20 11:12:35 +01:00
Christophe Bliard 91340b94b4 Remove unused variable 2025-01-14 15:00:11 +01:00
Oliver Günther 61fa6a4e70 Make cuprite the default 2025-01-14 10:20:35 +01:00
Oliver Günther a01e66cce0 Set accept-lang in cuprite 2024-09-25 15:15:19 +02:00
Christophe Bliard 8fd3537207 Remove no longer needed Cuprite patch
https://github.com/rubycdp/cuprite/pull/217 has been merged, `save_path`
is correctly taken into account now.
2024-09-19 09:59:31 +02:00
Ivan Kuchin 4911b8a149 remove years from copyrights (except for COPYRIGHT file) 2024-07-31 15:02:49 +02:00
ulferts 3b2121f733 Revert "Merge remote-tracking branch 'origin/release/13.4' into dev"
This reverts commit 40b2bbeb09, reversing
changes made to b4c6cb17cc.
2024-03-21 11:31:17 +01:00
Ivan Kuchin 7787e457a3 Revert "Merge branch 'dev' into release/13.4"
This reverts commit a901541269, reversing
changes made to e573ca00b7.
2024-03-20 20:19:08 +01:00
Ivan Kuchin 9e4934cd0a change quotes using rubocop --only Style/StringLiterals,Style/QuotedSymbols -a 2024-03-20 18:05:22 +01:00
Dombi Attila fcdce72bb4 Stop raising pending connection errors in ferrum 2024-02-01 14:23:18 +02:00
Christophe Bliard 8fa8584538 Run rubocop --autocorrect on all files
Only the safe cops have run. rubocop version is 1.59.0.
2024-01-05 15:27:09 +01:00
Aaron Contreras d35d0d291e Bump process_timeout to 20 seconds
* Aids in `Ferrum` connection errors.
2023-10-27 14:53:51 -05:00
Aaron Contreras 55f5686580 Disable smooth scrolling in cuprite tests
This article explains the reasons in detail: https://codemeister.hashnode.dev/capybara-cuprite-and-a-slow-scrolling-chrome-arm
2023-10-27 07:41:26 -05:00
Aaron Contreras 32b6536136 Rename ENV to be OpenProject specific 2023-10-17 08:50:14 -05:00
Aaron Contreras 11fdb27af0 Add configurable slowmo option to cuprite specs
Have you ever wanted to debug a spec in headful mode but it's running
way too fast to tell what's going on? Adding a `SLOMO` environment
variable lets you add a delay (in seconds) to every action taken by
the driver.

Setting

```
SLOWMO=0.2
```

is a pretty good delay in order to be able to nicely inspect what's going
on and slows down the spec run enough to understand it.

Hope this helps everyone as it's helped me!
2023-10-17 08:34:48 -05:00
Aaron Contreras 2fd283ec44 Standardize resolution in Cuprite Browser
* Sets 1920x1080 as the default resolution for both headless and
  headful mode.

* Adds an ENV variable to customize the browser's window resolution
  when running in headful mode (perhaps because you're working on
  your laptop and 1920x1080 is too big to fit your screen).
2023-09-15 02:27:42 +02:00
Oliver Günther fb60bc9184 Wrap cuprite runner in ensure block 2023-08-22 15:38:12 +02:00
Aaron Contreras 2c52e5aa48 Switch modules/meeting to cuprite 2023-06-29 09:25:05 -05:00
Aaron Contreras e939dd38cd Switch modules/job_status to cuprite 2023-06-28 05:19:12 -05:00
Aaron Contreras a5a136d1c2 Switch modules/backlogs to cuprite 2023-06-28 05:19:12 -05:00
Aaron Contreras b82ecf77ff Switch modules/avatars to cuprite 2023-06-28 05:19:12 -05:00
Christophe Bliard c01e87a377 Switch projects/export_spec to cuprite 2023-06-28 05:19:11 -05:00
Aaron Contreras 51d23109c8 Switch custom_fields/multi_user_custom_field_spec to cuprite 2023-06-28 05:18:57 -05:00
Aaron Contreras 86cde8f118 Register and toggle Cuprite driver
Sets up a barebones Cuprite initialization and toggles the javascript
driver to use depending on metadata attached to the example/group.
2023-06-28 05:18:52 -05:00