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

feat: clap wrapper around sqlness #2400

Merged
merged 3 commits into from
Sep 16, 2023
Merged

feat: clap wrapper around sqlness #2400

merged 3 commits into from
Sep 16, 2023

Conversation

Lilit0x
Copy link
Contributor

@Lilit0x Lilit0x commented Sep 14, 2023

I hereby agree to the terms of the GreptimeDB CLA

What's changed and what's your intention?

Added clap to the sqlness runner to improve the interface by providing help messages and allowing configurations.

Please explain IN DETAIL what the changes are in this PR and why they are needed:
sqlness can now accept arguments to be configured with when running tests. Below is the result of the help command after running: cargo sqlness -h

SQL Harness for GrepTimeDB

Usage: sqlness-runner [OPTIONS]

Options:
  -c, --case-dir <CASE_DIR>                Directory of test cases
  -f, --fail-fast...                       Fail this run as soon as one case fails if true
  -e, --env-config-file <ENV_CONFIG_FILE>  Environment Configuration File [default: config.toml]
  -t, --test-filter <TEST_FILTER>          Name of test case to be matched [default: ]
  -h, --help                               Print help
  -V, --version                            Print version

All arguments assume their default values when omitted from the command line. To use all arguments(or some):

cargo sqlness -f -c /path/to/testcase -e example.toml -t aggregation

Checklist

  • I have written the necessary rustdoc comments.
  • I have added the necessary unit tests and integration tests.

This PR references #2380

@codecov
Copy link

codecov bot commented Sep 14, 2023

Codecov Report

Merging #2400 (145b5ca) into develop (d1adb91) will decrease coverage by 0.07%.
Report is 1 commits behind head on develop.
The diff coverage is n/a.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2400      +/-   ##
===========================================
- Coverage    77.53%   77.46%   -0.07%     
===========================================
  Files          717      717              
  Lines       113984   113984              
===========================================
- Hits         88373    88299      -74     
- Misses       25611    25685      +74     

tests/runner/src/main.rs Outdated Show resolved Hide resolved
tests/runner/src/main.rs Outdated Show resolved Hide resolved
tests/runner/src/main.rs Outdated Show resolved Hide resolved
tests/runner/src/main.rs Outdated Show resolved Hide resolved
tests/runner/src/main.rs Outdated Show resolved Hide resolved
Copy link
Member

@waynexia waynexia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, appreciate it ❤️

Copy link
Contributor

@evenyag evenyag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@evenyag evenyag added this pull request to the merge queue Sep 16, 2023
Merged via the queue into GreptimeTeam:develop with commit 0a692aa Sep 16, 2023
11 checks passed
paomian pushed a commit to paomian/greptimedb that referenced this pull request Oct 19, 2023
* feat: wrapped sqlness with clap to provide nice interface

* fix: added spaces and changed -f flag to bool
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

Successfully merging this pull request may close these issues.

3 participants