-
Create a folder under src/
for your test files (each file typically includes tests for one category)
-
Get the package dependencies (npm install
)
-
Import the required utilities (refer to other tests as an example):
import { category, expect, test } from '@datagrok-libraries/utils/src/test';
-
Write some tests
-
Import your test files in src/package-test.ts
-
Publish the package
-
Open Datagrok and start the console (~
or Windows | Console
)
-
Launch tests for a category via ApiTests:test(category="category-name")
, e.g., ApiTests:test(category="Layouts")
, or a specific test via ApiTests:test(category="category-name", test="test-name")
, e.g., ApiTests:test(category="Layouts", test="ViewLayout.toJson()")
, and wait for the results