Files
directus/tests/blackbox
Rijk van Zanten 2bc226d16f Change license to BSL-1.1 (#18330)
* Change license to BSL1.1

* Mark major version

* Fix formatting

* Remove duplicate heading

* Update formatting

* Copy paste error

* Update license

* Update license

* Format covenants

* Update readme.md

* Update licenses for packages

* Update readme.md

* Update contributors.yml

OG... but to be clear, rijkvanzanten is the one who really built all of this ❤️

* Tweak license in openapi

* Update packages/specs/src/openapi.yaml

* Add MIT license headers

* Use v10 in examples

* Update additional examples

* Update generate-extensions-entrypoint.test.ts

* Update tests to use latest v9 and v10 versions

* use lowercase for naming consistency

* change casing for api license

* Update migrations doc

* Update dictionary

* Consistent ordering of license field in app/package.json

* Use major version in specs again (but as string)

So it's valid for all v10 versions

* Consolidate readme's

---------

Co-authored-by: Ben Haynes <ben@directus.io>
Co-authored-by: Pascal Jufer <pascal-jufer@bluewin.ch>
Co-authored-by: ian <licitdev@gmail.com>
Co-authored-by: Azri Kahar <42867097+azrikahar@users.noreply.github.com>
2023-04-26 14:10:42 -04:00
..
2023-04-14 17:40:50 -04:00
2023-04-14 17:40:50 -04:00
2023-04-14 17:40:50 -04:00
2023-04-14 17:40:50 -04:00
2023-04-14 17:40:50 -04:00
2023-04-14 17:30:56 -04:00
2023-04-11 18:28:37 +02:00

Blackbox tests

Setup

Make sure the containers for the databases are running by running docker compose up -d in this folder.

Directus needs to be deployed with pnpm --filter directus deploy --prod dist. When using the test:blackbox script in the workspace root (pnpm -w run test:blackbox) this is already done.

Running tests locally

Run pnpm -w run test:blackbox to run the blackbox tests for every supported database vendor.

Prepend TEST_SAVE_LOGS=trace to get trace logs at server-logs-* in this folder.

Testing a specific database

Provide a csv of database drivers in the TEST_DB environment variable to test specific databases:

TEST_DB=cockroachdb pnpm -w run test:blackbox

Using an existing Directus instance

The test suite will spin up a fresh copy of the Directus API from the current build. To use an already running copy of Directus, set the TEST_LOCAL flag:

TEST_DB=cockroachdb TEST_LOCAL=true pnpm -w run test:blackbox

This will use 127.0.0.1:8055 as the URL for every test. Note: make sure to connect your local Directus database instance to the test database container found in docker-compose in this folder.