Skip to content

feat: Support unit test (non-analysis test) types of tests in rules_testing#46

Merged
copybara-service[bot] merged 0 commit intomasterfrom
test_539366877
Jun 12, 2023
Merged

feat: Support unit test (non-analysis test) types of tests in rules_testing#46
copybara-service[bot] merged 0 commit intomasterfrom
test_539366877

Conversation

@copybara-service
Copy link

@copybara-service copybara-service bot commented Jun 11, 2023

feat: Support unit test (non-analysis test) types of tests in rules_testing

This adds support to write tests of general Starlark code that doesn't require
analysis phase information. While this was possible to do with enough work,
it's a bit of boiler plate to do so. This moves that boiler plate into
rules_testing, so that users just need to define their verification function.

Also makes test_suite able to handle both basic tests (ones that are only
an implementation function, like most unit tests) and regular tests (tests
that require a loading-phase setup process, like analyss tests).

Also creates a best practices doc. Some of the same advice pertains across
test suite, unit test, and analysis test.

Closes #37

@copybara-service copybara-service bot force-pushed the test_539366877 branch 6 times, most recently from c41c65b to d031db1 Compare June 12, 2023 20:13
@copybara-service copybara-service bot closed this Jun 12, 2023
@copybara-service copybara-service bot merged commit 6eeefb3 into master Jun 12, 2023
@copybara-service copybara-service bot deleted the test_539366877 branch June 12, 2023 20:22
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.

Add support for unit test style tests (non-analysis tests)

0 participants