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

Test storage-plus with iterator disabled #438

Merged
merged 2 commits into from
Sep 19, 2021
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
12 changes: 6 additions & 6 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1001,17 +1001,17 @@ jobs:
keys:
- cargocache-v2-storage-plus:1.53.0-{{ checksum "~/project/Cargo.lock" }}
- run:
name: Build library for native target
command: cargo build --locked
name: Build library for native target (no iterator)
command: cargo build --locked --no-default-features
- run:
name: Run unit tests
command: cargo test --locked
name: Run unit tests (no iterator)
command: cargo test --locked --no-default-features
- run:
name: Build library for native target (with iterator)
command: cargo build --locked --features iterator
command: cargo build --locked
- run:
name: Run unit tests (with iterator)
command: cargo test --locked --features iterator
command: cargo test --locked
- save_cache:
paths:
- /usr/local/cargo/registry
Expand Down
2 changes: 1 addition & 1 deletion packages/storage-plus/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ default = ["iterator"]
iterator = ["cosmwasm-std/iterator"]

[dependencies]
cosmwasm-std = { version = "0.16.0" }
cosmwasm-std = { version = "0.16.0", default-features = false }
schemars = "0.8.1"
serde = { version = "1.0.103", default-features = false, features = ["derive"] }
3 changes: 1 addition & 2 deletions packages/storage-plus/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,4 @@ pub use path::Path;
#[cfg(feature = "iterator")]
pub use prefix::{range_with_prefix, Bound, Prefix};
#[cfg(feature = "iterator")]
pub use snapshot::SnapshotMap;
pub use snapshot::{SnapshotItem, Strategy};
pub use snapshot::{SnapshotItem, SnapshotMap, Strategy};
2 changes: 1 addition & 1 deletion packages/storage-plus/src/snapshot/mod.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#![cfg(feature = "iterator")]
mod item;
mod map;

pub use item::SnapshotItem;
maurolacy marked this conversation as resolved.
Show resolved Hide resolved
#[cfg(feature = "iterator")]
pub use map::SnapshotMap;

use crate::{Bound, Map, Prefixer, PrimaryKey, U64Key};
Expand Down