Commit Graph

1149 Commits

Author SHA1 Message Date
Balena CI
42dd4f75ac v14.0.17 2022-09-06 21:05:01 -04:00
Balena CI
6b36ccfddf v14.0.16 2022-09-06 13:48:02 -04:00
Balena CI
ba66b10c0e v14.0.15 2022-08-24 17:33:20 -04:00
Felipe Lalanne
6d004f0994 Setup docker-compose.test
This allows to run integration tests during development and on CI
with the right dependencies. There are several changes that this
involves, but the gist of it is that a test environment is setup using
`docker-compose.test.yml`. This file is loaded by `resin-ci` during the
build, and ensures that integration tests are ran after setting up all
requirements. This commit also defines a test environment command that
can be setup using `npm run test:env` in order to run tests in a local
development machine.
2022-08-24 16:07:20 -04:00
Felipe Lalanne
ba51ca5fc0 Add mocha-pod for running integration tests
This ensure that whenever integration tests are ran, they
are executed in a containerized environment.
2022-08-24 14:29:17 -04:00
Felipe Lalanne
44f3e9ccdb Add command to spawn a development environment
For development, now doing `npm run dev` will spawn containers with the
necessary dependencies for developing and testing the supervisor.
2022-08-24 14:29:17 -04:00
Felipe Lalanne
c1e6dadeb4 Create test/unit and test/integration folders
This sets up the new `test/unit` and `test/integration` folders
and starts classification of some of the test files.

Note that unit tests include, `fs-utils` and `system-info` tests.

While these tests interact with the filesystem, the implementation
of these modules is simple enough, and the tests are fast enough to
allow these tests to fall under the `unit` test category (according to
test/README)

Change-type: patch
2022-08-24 14:28:36 -04:00
Felipe Lalanne
e1e35eb83b Move the current test suite under test/legacy
We are refactoring the supervisor test suite into unit tests (for
algorithms an domain model tests) and integration
tests (for interaction with out-of-process dependencies).
This means the current test suite needs to be classified into
these two categories, and fixed whenever possible.

This commit moves the test suite under the `test/legacy` folder, this
folder should be progressively migrated and eventually removed.
Subsequent commits will begin to split these files into unit and
integration whenever possible.

Depends-on: #1996
Change-type: patch
2022-08-22 17:21:51 -04:00
Balena CI
0d42ec5698 v14.0.14 2022-08-23 00:02:38 +03:00
Felipe Lalanne
71eaa3327e Use tsconfig-paths for easier access to the source
Currently, tests only can import source code modules through relative
paths `../../`. This makes it very difficult to refactor and organize
tests in folders as the paths change.

[tsconfig-paths](https://www.npmjs.com/package/tsconfig-paths) allows to
reference the source through an alias defined in the "paths" section of
tsconfig.json
2022-08-18 12:23:31 -04:00
Felipe Lalanne
1439ee30f2 Move sinon to dev dependencies
Sinon was added to the production dependencies by mistake in a previous
build. This is a module only used for testing so this fixes that error.
2022-08-18 12:23:31 -04:00
Felipe Lalanne
274503feb3 Simplify test commands in package.json
The supervisor used to perform tests both for the transpiled code (after
tsc) and one for the typescript code (using
ts-node/register/transpile-only). There is not really a reason for this
and this added complexity to the test configuration. This used to make
testing harder, as the built code didn't include source maps, meaning
the tests did not point to the right code.

Since we want to split tests in unit and integration tests as the next
test improvement, it makes sense to simplify these commands before
adding more complexity.

Change-type: patch
2022-08-18 12:23:20 -04:00
Balena CI
d83a37e6fd v14.0.13 2022-08-03 02:59:36 +04:00
Balena CI
936ada7f64 v14.0.12 2022-07-19 00:34:22 +03:00
Balena CI
86112e59bf v14.0.11 2022-07-18 22:20:48 +03:00
Balena CI
ac933ad3ef v14.0.10 2022-07-14 01:16:48 +03:00
Balena CI
d11d4fba91 v14.0.9 2022-07-07 00:27:14 +03:00
Balena CI
dc8b75485c v14.0.8 2022-06-27 19:38:31 +03:00
Balena CI
7e5a06d3f8 v14.0.7 2022-06-22 23:12:46 +03:00
Balena CI
2de0d5901d v14.0.6 2022-06-16 02:33:49 +03:00
Balena CI
c1bfbd5f3d v14.0.5 2022-06-14 23:37:58 +03:00
Balena CI
51c5456af9 v14.0.4 2022-06-14 00:58:34 +03:00
Balena CI
c0fee7839b v14.0.3 2022-06-07 23:12:14 +03:00
Balena CI
888ffa700d v14.0.2 2022-06-07 06:04:47 +03:00
Balena CI
d9186649a6 v14.0.1 2022-06-03 01:26:19 +03:00
Balena CI
27ed56f7fe v14.0.0 2022-06-02 02:08:00 +03:00
Balena CI
33ad877c67 v13.1.11 2022-05-27 17:54:14 +03:00
Balena CI
564ff186e7 v13.1.10 2022-05-23 21:55:37 +03:00
Balena CI
b361b8eebe v13.1.9 2022-05-23 18:01:00 +03:00
Balena CI
9549539eb2 v13.1.8 2022-05-18 00:55:47 +03:00
Balena CI
713d39a85e v13.1.7 2022-05-17 18:46:23 +03:00
Balena CI
6620bca7bd v13.1.6 2022-05-06 22:05:50 +03:00
Balena CI
cbd74954b3 v13.1.5 2022-05-06 21:29:08 +03:00
Balena CI
5686cc363d v13.1.4 2022-04-28 21:29:01 +03:00
Balena CI
4557644149 v13.1.3 2022-04-20 22:38:47 +03:00
Balena CI
9aa50eea8a v13.1.2 2022-04-18 23:34:21 +03:00
Balena CI
81a8705ff8 v13.1.1 2022-04-13 22:29:32 +03:00
Balena CI
f5ca7e87f0 v13.1.0 2022-04-12 22:27:08 +03:00
Christina Wang
e9738b5f78 Modify update lock module to use new lockfile binary and library
Also uninstall lockfile NPM package as we're no longer using it

Signed-off-by: Christina Wang <christina@balena.io>
2022-04-12 12:02:28 -07:00
Balena CI
a2f739789d v13.0.3 2022-04-08 20:44:13 +03:00
Balena CI
ebdfff10ad v13.0.2 2022-04-08 05:58:26 +03:00
Balena CI
fa9074ce76 v13.0.1 2022-04-05 17:38:16 +03:00
Balena CI
ffc61ee0b4 v13.0.0 2022-03-29 00:01:51 +03:00
Felipe Lalanne
063bd400a4 Convert target state in local endpoints
Convert target state from to v3 in `/v2/local/target-state`. Add tests
for target state conversion
2022-03-22 19:08:03 -03:00
Balena CI
474fc4e890 v12.11.43 2022-03-22 01:57:31 +02:00
Balena CI
37a82e2dd6 v12.11.42 2022-03-19 00:35:28 +02:00
Balena CI
aa023051f6 v12.11.41 2022-03-16 23:13:15 +02:00
Balena CI
260737a570 v12.11.40 2022-03-16 21:14:58 +02:00
Balena CI
702efb2d14 v12.11.39 2022-03-16 05:19:57 +02:00
20k-ultra
2fdb83839c Move report throttle out of reporting logic
Change-type: patch
Signed-off-by: 20k-ultra <3946250+20k-ultra@users.noreply.github.com>
2022-03-15 22:53:34 -04:00