Skip to content

NeowayLabs/abad

Repository files navigation

abad

GoDoc Build Status Go Report Card

Abad stands for Abaddon the destroyer and torturer of men.

Why this name ? Because developing this will be torture, we have been forsaken by God and left on the hands of a torturing angel (we must have done something pretty awful).

End to End Tests

To run the end to end tests you can run:

make test-e2e

These tests assume that you have both d8 and abad installed on the host that is running the tests. d8 is a repl/debugger from the V8 engine, which is our reference implementation used to compare if we are interpreting JavaScript code correctly.

As you can imagine, compiling V8 is not exactly easy...or fun. So we provide a docker image for this. To run the tests inside the docker dev environment you can run:

make dev-test-e2e

Adding new tests is very easy, just add new code samples to tests/e2e/testdata and they will imediately be tested when you run the end to end tests.

If you need to checkout the behavior of some JS code on the V8 engine you can run:

make dev-d8 code=<relative path to JS code inside project dir>

Yeah the JS file with the code has to be inside the project and the path must be relative (because of docker volume mapping stuff).

For example, to run a test.js file inside the project root run:

make dev-d8 code=test.js