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

Reduce code duplication in integration tests #82

Merged
merged 2 commits into from
Feb 22, 2023

Conversation

linhr
Copy link
Contributor

@linhr linhr commented Feb 15, 2023

What type of PR is this?

  • bug
  • feature
  • enhancement (small refactoring)

What problem(s) does this PR solve?

Issue(s) number: N/A

Description:

The integration tests contain duplicated code for initializing session, defining schema, and executing nGQL statements, etc. We can do some refactoring to extract shared logic for all tests.

How do you solve it?

I refactored a few test classes to make them inherit from NebulaITTestBase which contains shared logic for test setup. There is no change to the functionality.

Special notes for your reviewer, ex. impact of this fix, design document, etc:

N/A

Copy link
Contributor

@Nicole00 Nicole00 left a comment

Choose a reason for hiding this comment

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

LGTM!Great extracting job, thanks!

@Nicole00 Nicole00 merged commit 6b3cad3 into vesoft-inc:master Feb 22, 2023
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.

2 participants