Open wonglkd opened 1 year ago
1) I figure there are multiple ways to do tests, please feel free to suggest changes or turn down this PR! 2) As a side-effect, this appears to show failing tests on the following OSes:
Ignored tests (and failing OSes)
Failing, not yet ignored
We really appreciate you working on this! This will save us so much time maintaining OSS builds going forward :-D
shm-test-test_page_size
This test is expected to fail since it relies on adjusting page size. Internally, we also have this disabled on test services (since the test needs sudo permission to manipulate page size).
"Util.SysctlTests" is also expected to fail because it expects to change overcommit settings in the kernel
The other test failures are not expected. I'll go through the logs.
A standalone bash script keeps it within GitHub Actions instead of adding an external dependency (most FB OSS repos use GH actions alone, with RocksDB using CircleCI and HHVM using NixCI). Still, it would be nice to have proper test insights (e.g., CircleCI's)
RocksDB team develops for OSS first and then imports into our internal source control. CacheLib and most other FB OSS projects develops primarily within FB's internal setup, and then a system picks up our changes and push to Github. It's a trade-off between internal dev velocity and OSS dev velocity.
Sounds good! I hope it helps! ~GitHub's CI runners do have sudo, btw, so one could add a step in the test script to adjust that. Is there a recommended setting?~ (Realised that for OSes running within Docker containers, one will get a sysctl: permission denied on key "vm.nr_hugepages"
even with sudo. For native builds, setting the value works, but the test still fails.)
Also, since GitHub Actions has free unlimited mins on OSS repos anyway, perhaps one could consider enabling CI on every push? Scheduled builds are helpful but one still needs to line up the timestamps and manually bisect the exact commit or code change that causes a break - plus, it's free anyway.
Btw, is there any expectation that tests are run sequentially vs in parallel?
Btw, is there any expectation that tests are run sequentially vs in parallel?
Internally we run them in parallel. That said, sequential is fine as long as tests finish in a reasonable time.
Also, since GitHub Actions has free unlimited mins on OSS repos anyway, perhaps one could consider enabling CI on every push? Scheduled builds are helpful but one still needs to line up the timestamps and manually bisect the exact commit or code change that causes a break - plus, it's free anyway.
Good to know. I wasn't aware github actions are free actually. Previously we had to pay for it (but maybe that was when we were first setting up this repo and it was private then).
Test runner script
$TO_SKIP
$OPTIONAL
$OPTIONAL
tests have their failures ignored. List needs to be manually updated.$PARALLELISM = 10
)Trade-offs considered
$OPTIONAL
. If not, one can comment the last line ofrun_tests.sh
so that builds will not fail, with the disadvantage that one needs to view individual workflows to see the summary. (Or write a script to compile that)Build time impact (net gain):
Test plan:
Screenshots of job summary page (accessible via Checks tab on PRs, or in Actions tab)