Page MenuHomePhabricator

[services] Tunnelbroker - Changing Buildkite commands for Tunnelbroker to run `cargo`
ClosedPublic

Authored by max on Oct 21 2022, 3:11 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Nov 26, 5:14 PM
Unknown Object (File)
Mon, Nov 25, 3:46 AM
Unknown Object (File)
Mon, Nov 25, 3:46 AM
Unknown Object (File)
Mon, Nov 25, 3:46 AM
Unknown Object (File)
Sun, Nov 24, 11:04 PM
Unknown Object (File)
Sun, Nov 24, 11:04 PM
Unknown Object (File)
Sun, Nov 24, 11:04 PM
Unknown Object (File)
Sun, Nov 24, 11:04 PM

Details

Summary

This diff introduces changes to the Buildkite to change the build commands for Tunnelbroker from cmake to use cargo build and cargo test instead. We are removing the target directory before building to remove the cache.
Also, the building and running of the tests for the legacy C++ code are added.

Related Linear task: ENG-2062

Test Plan

To test manually, we can run the Buildkite commands in the root of the repo to ensure they are successful.

Running the following commands in a repo root directory will be expected to succeed:

cd services/tunnelbroker
rm -rf target
nix develop --accept-flake-config -c bash -c "cargo build && cargo test"
cd src/libcpp/test
rm -rf build
nix develop --accept-flake-config -c bash -c "cmake -B build . && make -C build -j"
build/bin/runTests --gtest_filter="-AmqpManager*:DatabaseManager*"

Diff Detail

Repository
rCOMM Comm
Branch
ci-update-nix-build
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

max held this revision as a draft.
max published this revision for review.Oct 21 2022, 3:18 PM
max edited the summary of this revision. (Show Details)
max edited the test plan for this revision. (Show Details)
max added reviewers: jon, varun, marcin.
max edited the test plan for this revision. (Show Details)

Adding of the gTest building and running for the legacy C++ code.

max edited the test plan for this revision. (Show Details)
This revision is now accepted and ready to land.Oct 26 2022, 2:06 PM
This revision now requires review to proceed.Oct 27 2022, 2:31 AM
tomek added inline comments.
.buildkite/tunnelbroker_unittests.yml
10

Can we be less specific while filtering the tests? Currently, if we want to introduce a new test, we would need to update this specification.

This revision is now accepted and ready to land.Oct 27 2022, 5:01 AM
max added inline comments.
.buildkite/tunnelbroker_unittests.yml
10

Can we be less specific while filtering the tests? Currently, if we want to introduce a new test, we would need to update this specification.

We are filtering the tests that require running a localstack and rabbitmq to pass that's why we are filtering them here.
The C++ codebase for the Tunnelbroker is frozen now and we are switching to using Rust, I assume that the new updates will be in the Rust codebase. That's why this is highly unlikely that we will introduce some new tests for these filtered patterns.

max marked an inline comment as done.

Changing the binary location directory to build instead of build/bin according to changes in D5430.

Rebasing on the parent changes.

This revision was landed with ongoing or failed builds.Nov 7 2022, 6:24 AM
This revision was automatically updated to reflect the committed changes.