Skip to content

Commit

Permalink
Start refactoring keys of sentVscPackets map
Browse files Browse the repository at this point in the history
  • Loading branch information
p-offtermatt committed Jan 26, 2024
1 parent 5eb1ae5 commit 9376e2b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion tests/mbt/model/ccv_model.qnt
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ module ccv_model {
val CanSendVscPackets =
not(ConsumerChains.exists(
consumer =>
currentState.providerState.outstandingPacketsToConsumer.get(consumer).length() > 0
currentState.providerState.outstandingPacketsToConsumer.getOrElse(consumer, List()).length() > 0
))

val CanReceiveVscPackets =
Expand Down
3 changes: 3 additions & 0 deletions tests/mbt/model/ccv_utils.qnt
Original file line number Diff line number Diff line change
Expand Up @@ -409,6 +409,9 @@ module ccv_utils {
status == RUNNING
}

// Returns the set of all consumer chains.
pure def GetConsumers(providerState: ProviderState): Set[Chain] = providerState.consumerStatus.keys()

// Returns the set of all consumer chains that currently have the status RUNNING.
pure def getRunningConsumers(providerState: ProviderState): Set[Chain] = {
providerState.consumerStatus.keys().filter(
Expand Down

0 comments on commit 9376e2b

Please sign in to comment.