Commit Graph

16 Commits

Author SHA1 Message Date
Alex Hall
7a6464ae5a
Run tests on Python 3.9, 3.10, and 3.11 in GHA (#597) 2023-07-29 00:24:09 +02:00
Paul Fitzpatrick
70935a4fa4
skip building test harness in docker image (#551)
A small test harness bundle was recently added that is breaking the docker image build. It could be added to the docker image, but that would introduce a bunch of extraneous test file dependencies. So this tweaks the build to simply skip the test bundle if its primary source file is not found.

Also added some other test fixes along the way:
  * make a custom widget test more reliable
  * update a localization test now that `pt` exists
  * store more log info in artifact on error
2023-06-30 05:50:40 -04:00
Paul Fitzpatrick
01069a69b0
adapt tests after switch to parallel runs (#547)
Some browser tests are now run in parallel. A few tests have become unreliable, and need a little love. Also, create and save mocha webdriver logs.
2023-06-28 17:17:14 -04:00
Paul Fitzpatrick
bcbf57d590 (core) bump mocha version to allow parallel tests; move more tests to core
Summary:
This uses a newer version of mocha in grist-core so that tests can be run in parallel. That allows more tests to be moved without slowing things down overall. Tests moved are venerable browser tests; only the ones that "just work" or worked without too much trouble to are moved, in order to keep the diff from growing too large. Will wrestle with more in follow up.

Parallelism is at the file level, rather than the individual test.

The newer version of mocha isn't needed for grist-saas repo; tests are parallelized in our internal CI by other means. I've chosen to allocate files to workers in a cruder way than our internal CI, based on initial characters rather than an automated process. The automated process would need some reworking to be compatible with mocha running in parallel mode.

Test Plan: this diff was tested first on grist-core, then ported to grist-saas so saas repo history will correctly track history of moved files.

Reviewers: jarek

Reviewed By: jarek

Subscribers: jarek

Differential Revision: https://phab.getgrist.com/D3927
2023-06-27 02:55:34 -04:00
Paul Fitzpatrick
4be4acca6e
run grist-core test batches in parallel (#444)
This sets up a framework for running tests in parallel.
It increases the total time taken (since some steps are
repeated) but reduces the turn-around time significantly
overall.

The main objective is to make it possible to release more
test batches to grist-core without bringing CI to a crawl.

The clever little test/split-test.js script is from the
Grist Labs mono-repo and is Dmitry's work.

I considered doing the build in one job, and copying
it to test jobs, since it feels wasteful to repeat it.
That may be worth trying, especially if we start getting
jobs backing up (total concurrent Linux jobs on free plan
is quoted at 20).

It might also be worth looking at doing some tests in
parallel on the same worker, perhaps using the relatively
new MOCHA_WORKER_ID feature, since the tests are often not
actually CPU or I/O bound.
2023-03-03 09:53:33 -05:00
Jarosław Sadziński
b0555564ac Linting before build 2023-01-03 17:23:31 +01:00
Jarosław Sadziński
7ff2ca954c Adding eslint to github actions 2023-01-03 17:23:31 +01:00
Paul Fitzpatrick
103ebbb045
add MinIO tests (#381)
Extends workflow to test snapshots with minio.
2022-12-22 12:58:39 -05:00
George Gevoian
d69ac6a789 Run python tests during main workflow 2022-10-02 23:10:32 -07:00
Paul Fitzpatrick
c588d58959
use python3 for workflows (#267)
Use python3 for running tests. Grist has supported python3 for a while,
and is slowly slowly starting to inch away from python2 support. Grist
now needs python3 when doing imports, although python2 is still supported
for regular document operation.
2022-09-06 11:46:52 -04:00
Jarosław Sadziński
a44a59e591 Tweaking logging in github action and test_under_docker script 2022-08-10 14:16:27 +02:00
Jarosław Sadziński
c7a6784873 Removing grist logs from tests 2022-08-10 13:33:08 +02:00
Paul Fitzpatrick
24522e61ff
remove stray redis dependency, and upgrade node in tests (#173)
* remove stray redis dependency in test
* tweak handling of database connection between tests
* upgrade node versions in tests, type guessing in node 10 has problems
2022-03-28 15:43:47 -04:00
Paul Fitzpatrick
65ac8aaa85 (core) run test:docker target prior to pushing grist-core image
Summary:
This activates the new tests that can run on a grist-core image,
and will not push a new version to `latest` tag unless those tests
pass.

This also runs a smoke test in the regular CI tests, to confirm the
code continues to work without GRIST_TEST_LOGIN enabled.

Test Plan: tested on a fork of grist-core

Reviewers: georgegevoian

Reviewed By: georgegevoian

Differential Revision: https://phab.getgrist.com/D3186
2021-12-14 14:22:02 -05:00
Paul Fitzpatrick
6e3ec298f2 (core) regularly freshen grist-core:latest docker image
Summary:
 * Keeps `grist-core:latest` docker image up to date with grist-core
   source, with a daily cron job.
 * Update yarn.lock file.
 * In passing, tag current version for a versioned release.

When a push to `main` branch passes tests, the result is placed in `latest_candidate` branch. The cron job will update docker up from `latest_candidate`, placing code used for image in `latest` branch.

Test Plan: tested in a grist-core fork

Reviewers: georgegevoian

Reviewed By: georgegevoian

Differential Revision: https://phab.getgrist.com/D3156
2021-11-29 14:06:05 -05:00
Paul Fitzpatrick
45141ed438 (core) add CI github action for grist-core
Summary:
Activate CI for grist-core using github actions.  Can be improved
with caching but starting simple.

Test Plan: tested in a fork of grist-core

Reviewers: dsagal

Reviewed By: dsagal

Differential Revision: https://phab.getgrist.com/D2771
2021-04-12 17:17:17 -04:00