Skip to content

Conversation

oguzkocer
Copy link
Contributor

In our integration tests, we have been running read_test_credentials_from_file from every single test. This PR adds a build script to wp_api to generate a Rust source file from the test_credentials file to entirely skip that step.

Admittedly, this doesn't make that big of a difference in test execution time:

Screenshot 2024-06-20 at 02 09 44

Still, we won't be reading a file for every test run and that's good enough a win for me.

To Test

  • make test-server && make dump-mysql && make backup-wp-content-plugins
  • cargo test --test '*' -- --test-threads 1

@oguzkocer oguzkocer added this to the 0.1 milestone Jun 20, 2024
@oguzkocer oguzkocer enabled auto-merge (squash) June 20, 2024 06:12
@oguzkocer oguzkocer disabled auto-merge June 20, 2024 19:30
@oguzkocer oguzkocer requested a review from jkmassel June 20, 2024 23:14
@oguzkocer oguzkocer merged commit 5050918 into trunk Jun 21, 2024
@oguzkocer oguzkocer deleted the generate_test_credentials_as_a_build_step branch June 21, 2024 03:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants