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

Improve engine_correctness_tests for maintainability #134

Closed
4 tasks
V0ldek opened this issue May 18, 2023 · 1 comment · Fixed by #170
Closed
4 tasks

Improve engine_correctness_tests for maintainability #134

V0ldek opened this issue May 18, 2023 · 1 comment · Fixed by #170
Assignees
Labels
area: testcase Improvements to regular (non-prop) test coverage good first issue Good for newcomers help wanted External contributions welcome type: feature New feature or request type: reliability Tests, code quality
Milestone

Comments

@V0ldek
Copy link
Member

V0ldek commented May 18, 2023

Is your feature request related to a problem? Please describe.

  1. Cases are confusingly named, describing files and queries, but not what they're meant to test. When a test fails it's impossible to tell what exact part of the system failed, which is important.
  2. The JSON files themselves also have incosistent names, sometimes describing the document, other times the query use-case they want to stress.
  3. There is no consitency in which files are tested for prettified vs compressed versions.
  4. Some tests verify only counts, some verify both counts and byte indices, resulting in inconsistencies and duplication of test cases.

Describe the solution you'd like

  1. All cases should describe what they test in high-level, declarative means. Each test cases has a reason for its existence.
  2. JSON file names should describe their structure, not what cases they're used for. A slight exception for this is the wikidata dataset, for which "structure" simply means "it's the wikidata real-life dataset".
  3. There should be automatic verification of that, and all tests should have prettified and compressed versions. A script should automatically create the missing counterpart, integrated with the justfile. Part of just verify should check that each test has a counterpart.
  4. We should always verify byte indices, since correct indices imply correct counts. In case of large result sets we should have snapshot files with the output.
@V0ldek V0ldek added type: feature New feature or request help wanted External contributions welcome good first issue Good for newcomers mod: engine type: reliability Tests, code quality area: testcase Improvements to regular (non-prop) test coverage labels May 18, 2023
@github-actions github-actions bot added the acceptance: triage Waiting for owner's input label May 18, 2023
@github-actions
Copy link

Tagging @V0ldek for notifications

@V0ldek V0ldek added this to the v1.0.0 milestone May 18, 2023
@github-actions github-actions bot added acceptance: go ahead Reviewed, implementation can start and removed acceptance: triage Waiting for owner's input labels May 18, 2023
@V0ldek V0ldek self-assigned this Jun 18, 2023
@V0ldek V0ldek moved this from Todo to In Progress in Active rsonpath development Jun 18, 2023
V0ldek added a commit that referenced this issue Jul 2, 2023
Engine tests were rewritten to use declarative TOML configurations
for ease of creating new tests, maintenance and debugging ease.
Test coverage was increased, since compressed variants of inputs are
automatically generated and tested, and we now test all combinations
of input-engine-result types.

Ref #134
@github-project-automation github-project-automation bot moved this from In Progress to Merged in Active rsonpath development Jul 2, 2023
@github-actions github-actions bot removed the acceptance: go ahead Reviewed, implementation can start label Jul 2, 2023
@V0ldek V0ldek moved this from Merged to Released in Active rsonpath development Aug 2, 2023
@V0ldek V0ldek moved this from Todo to Released in Active rq development Apr 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: testcase Improvements to regular (non-prop) test coverage good first issue Good for newcomers help wanted External contributions welcome type: feature New feature or request type: reliability Tests, code quality
Projects
Status: Released
Development

Successfully merging a pull request may close this issue.

1 participant