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

tests: make integration testing faster #726

Merged
merged 2 commits into from
Jul 15, 2022
Merged

Conversation

better0fdead
Copy link
Contributor

@better0fdead better0fdead commented Jul 5, 2022

Separated integration tests from linter, unit, e2e and examples checks.
Result: ~15% faster testing.
Added pre-building of slow projects.
Total result: ~40-65% faster.
Closes #690

@better0fdead better0fdead linked an issue Jul 5, 2022 that may be closed by this pull request
@better0fdead better0fdead marked this pull request as draft July 5, 2022 14:29
@better0fdead better0fdead force-pushed the better0fdead/gh-609-tests branch 4 times, most recently from 982805a to acf5f8b Compare July 5, 2022 22:50
@better0fdead better0fdead marked this pull request as ready for review July 6, 2022 10:26
@better0fdead better0fdead changed the title workflow: separate integration tests from other checks tests: make integration testing faster Jul 6, 2022
@better0fdead better0fdead requested a review from 0x501D July 7, 2022 14:11
Copy link
Collaborator

@LeonidVas LeonidVas left a comment

Choose a reason for hiding this comment

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

Hi! Thank you for the patchset.
Generally I'm OK.
Please add to the commit body the reason and what profit we have.

magefile.go Show resolved Hide resolved
magefile.go Outdated Show resolved Hide resolved
magefile.go Outdated Show resolved Hide resolved
@LeonidVas
Copy link
Collaborator

LeonidVas commented Jul 13, 2022

Am I correct in assuming that further ticket work is planned or more ideas to accelerate testing?

Separated integration tests from linter, unit, e2e and examples checks,
because integration tests run longer then all other.
Result: 15% faster testing.

Part of #690
@better0fdead better0fdead force-pushed the better0fdead/gh-609-tests branch 5 times, most recently from 58ac602 to f53d0c9 Compare July 14, 2022 09:11
magefile.go Outdated
@@ -161,9 +161,19 @@ func Unit() error {
// Run integration tests
func Integration() error {
mg.Deps(GenerateGoCode)

build_projects_path := os.TempDir() + "/cartridge_cli_test_temp"
err := os.Mkdir(build_projects_path, 0777)
Copy link
Collaborator

Choose a reason for hiding this comment

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

0777 - looks like overkill (write description in comments).

@LeonidVas
Copy link
Collaborator

Am I correct in assuming that further ticket work is planned or more ideas to accelerate testing?

How about this question?

@better0fdead better0fdead force-pushed the better0fdead/gh-609-tests branch 2 times, most recently from a29d950 to 750a49b Compare July 14, 2022 11:12
Added pre-building of project_with_cartridge and default_project before integration tests.
Result: ~25-50% faster testing.

Closes #390
@better0fdead
Copy link
Contributor Author

Am I correct in assuming that further ticket work is planned or more ideas to accelerate testing?

How about this question?

In my opinion, at that state it is more profitable to do that issue #724, or think about #730. I suggest closing that issue for now. Total profit is ~50% from initial point.

Copy link
Collaborator

@LeonidVas LeonidVas left a comment

Choose a reason for hiding this comment

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

LGTM

@LeonidVas LeonidVas merged commit 4a4f08b into master Jul 15, 2022
@LeonidVas LeonidVas deleted the better0fdead/gh-609-tests branch July 15, 2022 08:09
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.

Understand why it takes so long to pass the tests
2 participants