Skip to content

Commit

Permalink
fix: dfx start --pocketic does not require --clean (#3984)
Browse files Browse the repository at this point in the history
* fix: dfx start --pocketic does not require --clean

* force

* fix
  • Loading branch information
mraszyk authored Nov 12, 2024
1 parent a08f9de commit 234c2a3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
8 changes: 8 additions & 0 deletions e2e/tests-dfx/start.bash
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ teardown() {
assert_command diff "$NETWORK_ID_PATH" "$NETWORK_ID_BY_SETTINGS_DIGEST_PATH"
}

@test "start and stop" {
dfx_start
dfx_stop

dfx_start
dfx_stop
}

@test "start and stop with different options" {
[[ "$USE_POCKETIC" ]] && skip "skipped for pocketic: clean required"
dfx_start --artificial-delay 101
Expand Down
3 changes: 2 additions & 1 deletion src/dfx-core/src/config/model/replica_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,8 @@ impl<'a> CachedConfig<'a> {
}
}
pub fn can_share_state(&self, other: &Self) -> bool {
self == other
// effective canister id does not matter for ability to share state
self.replica_rev == other.replica_rev && self.config == other.config
}
pub fn get_effective_canister_id(&self) -> Option<Principal> {
self.effective_canister_id
Expand Down

0 comments on commit 234c2a3

Please sign in to comment.