Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem: need a way to run quickcheck against subgraphs/agents #238

Open
sjmackenzie opened this issue Jun 7, 2018 · 0 comments
Open

Problem: need a way to run quickcheck against subgraphs/agents #238

sjmackenzie opened this issue Jun 7, 2018 · 0 comments

Comments

@sjmackenzie
Copy link
Member

sjmackenzie commented Jun 7, 2018

Solution:

A potential way to structure this, is to create a test.rkt file in the same directory as the subgraph/agent.

The test.rkt file should contain a quickcheck property definition, these definitions and the graphs to be tested against should all be packaged up and sent to the fvm for processing.

The test harness should be able to handle testing of a single node only for development purposes.

Property based checks should be run by the CI upon every commit.

A rackunit exception should be thrown if a property fails.

clacke added a commit to clacke/fractalide that referenced this issue Jul 10, 2018
This collection no longer exists.

Solution: Load fractalide/nodes/rkt/paging-jsend-get/main instead.

`raco test .` in the root of fractalide successfully runs the test.

This should be in `release.nix` and more modules should have tests in
their `test` submodule. But first we should make running node tests
more convenient, which I guess goes under fractalide#238. Once we have that,
quicktest is just one way to formulate a test case.

The way paging-jsend-get tests itself can be viewed as a first
prototype and an example of what kind of boilerplate we would
like to put into a convenience interface.

Instead of being an external module, test/mock could be a submodule --
if we think spreading files around doesn't look nice and if the mock
is small enough. It's possible that we could make a mock generator
macro that creates a mock for your needs as a submodule, to keep the
mock definition concise.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant