-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #65 from nodecosmos/GB_init_tests
Initialize Tests
- Loading branch information
Showing
22 changed files
with
710 additions
and
274 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
name: Test and Build | ||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
env: | ||
FORCE_COLOR: 1 | ||
CARGO_TERM_COLOR: always | ||
RUST_BACKTRACE: full | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 60 | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
- name: Setup 3-node Scylla cluster | ||
run: | | ||
sudo sh -c "echo 2097152 >> /proc/sys/fs/aio-max-nr" | ||
docker compose -f test/docker-compose.yml up -d --wait | ||
- name: Create Keyspace | ||
run: | | ||
docker exec scylla1 cqlsh -e \ | ||
"CREATE KEYSPACE charybdis WITH replication = {'class': 'NetworkTopologyStrategy', 'replication_factor': 2};" | ||
- name: Cache Dependencies | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
~/.cargo/bin | ||
~/.cargo/registry | ||
~/.cargo/git | ||
target | ||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | ||
- name: Update rust toolchain | ||
run: rustup update | ||
- name: Print rustc version | ||
run: rustc --version | ||
- name: Print rustfmt version | ||
run: cargo fmt --version | ||
- name: Print clippy version | ||
run: cargo clippy --version | ||
- name: Format check | ||
run: cargo fmt --verbose -- --check | ||
- name: Clippy check | ||
run: cargo clippy --verbose | ||
- name: Cargo check | ||
run: cargo check --verbose | ||
- name: Build | ||
run: cargo build --verbose | ||
- name: Install Charybdis Migration Tool | ||
run: cargo install --path charybdis-migrate --force | ||
- name: Run Charybdis Migration Tool | ||
run: migrate --keyspace charybdis --host 127.0.0.1:9042 --drop-and-replace | ||
- name: Run tests | ||
run: cargo test --verbose |
Oops, something went wrong.