We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ce7d867 commit b1d89acCopy full SHA for b1d89ac
packages/vm/src/cache.rs
@@ -706,6 +706,18 @@ mod tests {
706
cache.store_code(CONTRACT, true, true).unwrap();
707
}
708
709
+ #[test]
710
+ fn store_code_without_persist_works() {
711
+ let cache: Cache<MockApi, MockStorage, MockQuerier> =
712
+ unsafe { Cache::new(make_testing_options()).unwrap() };
713
+ let checksum = cache.store_code(CONTRACT, true, false).unwrap();
714
+
715
+ assert!(
716
+ cache.load_wasm(&checksum).is_err(),
717
+ "wasm file should not be saved to disk"
718
+ );
719
+ }
720
721
#[test]
722
// This property is required when the same bytecode is uploaded multiple times
723
fn store_code_allows_saving_multiple_times() {
0 commit comments