Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: bandits #11

Merged
merged 14 commits into from
Jul 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 7 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
- stable
steps:
- uses: actions/checkout@v3
- run: npm ci
- run: make test-data
- run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- run: cargo build --verbose
Expand All @@ -34,13 +35,6 @@ jobs:
os: [ubuntu, macos]
ruby: [3.0, 3.1, 3.2]

defaults:
run:
working-directory: ruby-sdk

env:
EPPO_API_KEY: ${{ secrets.EPPO_API_KEY }}

steps:
- uses: actions/checkout@v4

Expand All @@ -52,14 +46,16 @@ jobs:
cargo-cache: true
rubygems: '3.5.11'

- run: npm ci
- run: make test-data

- name: Install dependencies
run: bundle install
working-directory: ruby-sdk

- name: Build
run: bundle exec rake build

- name: Load test data
run: bundle exec rake test_refreshed_data
working-directory: ruby-sdk

- name: Run tests
run: bundle exec rspec
run: npm run with-server test:ruby
2 changes: 2 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ jobs:
- stable
steps:
- uses: actions/checkout@v3
- run: npm ci
- run: make test-data
- name: Install Rust toolchain
run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- name: Build Release
Expand Down
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@

# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
Cargo.lock
/Cargo.lock

# These are backup files generated by rustfmt
**/*.rs.bk

# MSVC Windows builds of rustc generate these, which store debugging information
*.pdb

/rust-sdk/tests/data
/sdk-test-data/
node_modules
ruby-sdk/eppo-server-sdk-0.3.0.gem
1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ resolver = "2"
members = [
"eppo_core",
"rust-sdk",
"./ruby-sdk/ext/eppo_rb",
]
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ help: Makefile
@sed -n 's/^##//p' $<

## test-data
testDataDir := eppo_core/tests/data/
testDataDir := sdk-test-data
branchName := main
githubRepoLink := https://github.com/Eppo-exp/sdk-test-data.git
.PHONY: test-data
Expand All @@ -38,4 +38,4 @@ ${testDataDir}:

.PHONY: test
test: ${testDataDir}
cargo test
npm test
5 changes: 4 additions & 1 deletion eppo_core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ repository = "https://github.com/Eppo-exp/rust-sdk"
license = "MIT"
keywords = ["eppo", "feature-flags"]
categories = ["config"]
rust-version = "1.65.0"
rust-version = "1.71.1"

[dependencies]
chrono = { version = "0.4.38", features = ["serde"] }
Expand All @@ -22,3 +22,6 @@ serde = { version = "1.0.198", features = ["derive"] }
serde_json = "1.0.116"
thiserror = "1.0.60"
url = "2.5.0"

[dev-dependencies]
env_logger = "0.11.3"
Loading
Loading