bigtestjs / server

All BigTest development has moved to https://github.com/thefrontside/bigtest
https://github.com/thefrontside/bigtest
2 stars 1 forks source link

Serve full test tree #99

Closed cowboyd closed 4 years ago

cowboyd commented 4 years ago

closes #94

Motivation

We had previously made the decision to serialize the tree representing the test in the GraphQL API as JSON in order to facilitate fetching it without resorting to complicated query generation via fragments or otherwise. However, the moment we needed to actually work with the tree by sending back test results in order to match the tree, it became clear that we'd want to have the result structure match the tree structure.

Approach

This goes back to serving the test tree as a strongly typed GraphQL structure that preserves the recursive nature. In addition to restoring the tree, each test is now annotated with both a path (Array) and an id (String) that are unique to that test node. This can be used to match test results with tests, and also to specify a subset of tests to run.

Finally, since it was easier to do at this point rather than not, the Manifest interface was updated to account for unique identification of manifests by URL.

Screenshots

image

Open Questions