Skip to content

Commit

Permalink
fix: disable integration tests that are broken on mac (#8412)
Browse files Browse the repository at this point in the history
I made two types of tests conditionally compiled to exclude them from running on macbooks - because they don't work on macs anyway. 

- test_two_deployments 
The test relies on the contract cache to be populated but the precompile method of the wasmtime runner doesn’t populate the cache
- test_wasmer2_upgrade 
The test checks transition from wasmer0 to wasmer2 but wasmer0 and wasmer2 are not available on macs
  • Loading branch information
wacban authored Jan 22, 2023
1 parent 6dcd6d9 commit 9d2a900
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions integration-tests/src/tests/client/features/wasmer2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ use near_primitives::hash::CryptoHash;
use near_primitives::transaction::{Action, FunctionCallAction, Transaction};
use nearcore::config::GenesisExt;

// This test fails on aarch because wasmer0 and wasmer2 are not available.
#[cfg_attr(all(target_arch = "aarch64", target_vendor = "apple"), ignore)]
#[test]
fn test_wasmer2_upgrade() {
let mut capture = near_o11y::testonly::TracingCapture::enable();
Expand Down
4 changes: 4 additions & 0 deletions integration-tests/src/tests/client/process_blocks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3473,6 +3473,7 @@ fn test_catchup_no_sharding_change() {
}
}

/// These tests fail on aarch because the WasmtimeVM::precompile method doesn't populate the cache.
mod contract_precompilation_tests {
use super::*;
use near_primitives::contract::ContractCode;
Expand Down Expand Up @@ -3511,6 +3512,7 @@ mod contract_precompilation_tests {
}

#[test]
#[cfg_attr(all(target_arch = "aarch64", target_vendor = "apple"), ignore)]
fn test_sync_and_call_cached_contract() {
let num_clients = 2;
let stores: Vec<Store> = (0..num_clients).map(|_| create_test_store()).collect();
Expand Down Expand Up @@ -3613,6 +3615,7 @@ mod contract_precompilation_tests {
}

#[test]
#[cfg_attr(all(target_arch = "aarch64", target_vendor = "apple"), ignore)]
fn test_two_deployments() {
let num_clients = 2;
let stores: Vec<Store> = (0..num_clients).map(|_| create_test_store()).collect();
Expand Down Expand Up @@ -3694,6 +3697,7 @@ mod contract_precompilation_tests {
}

#[test]
#[cfg_attr(all(target_arch = "aarch64", target_vendor = "apple"), ignore)]
fn test_sync_after_delete_account() {
let num_clients = 3;
let stores: Vec<Store> = (0..num_clients).map(|_| create_test_store()).collect();
Expand Down

0 comments on commit 9d2a900

Please sign in to comment.