Skip to content

Commit

Permalink
compile tests
Browse files Browse the repository at this point in the history
  • Loading branch information
rnbguy committed Apr 29, 2024
1 parent 23254c4 commit 931b99c
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 6 deletions.
10 changes: 8 additions & 2 deletions ibc-core/ics03-connection/types/src/events.rs
Original file line number Diff line number Diff line change
Expand Up @@ -393,11 +393,17 @@ mod tests {
assert_eq!(t.kind, t.event.kind);
assert_eq!(t.expected_keys.len(), t.event.attributes.len());
for (i, e) in t.event.attributes.iter().enumerate() {
assert_eq!(e.key, t.expected_keys[i], "key mismatch for {:?}", t.kind);
assert_eq!(
e.key_str().unwrap(),
t.expected_keys[i],
"key mismatch for {:?}",
t.kind
);
}
for (i, e) in t.event.attributes.iter().enumerate() {
assert_eq!(
e.value, t.expected_values[i],
e.value_str().unwrap(),
t.expected_values[i],
"value mismatch for {:?}",
t.kind
);
Expand Down
10 changes: 8 additions & 2 deletions ibc-core/ics04-channel/types/src/events/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1246,12 +1246,18 @@ mod tests {
assert_eq!(t.kind, t.event.kind);
assert_eq!(t.expected_keys.len(), t.event.attributes.len());
for (i, e) in t.event.attributes.iter().enumerate() {
assert_eq!(e.key, t.expected_keys[i], "key mismatch for {:?}", t.kind);
assert_eq!(
e.key_str().unwrap(),
t.expected_keys[i],
"key mismatch for {:?}",
t.kind
);
}
assert_eq!(t.expected_values.len(), t.event.attributes.len());
for (i, e) in t.event.attributes.iter().enumerate() {
assert_eq!(
e.value, t.expected_values[i],
e.value_str().unwrap(),
t.expected_values[i],
"value mismatch for {:?}",
t.kind
);
Expand Down
6 changes: 4 additions & 2 deletions ibc-testkit/src/fixtures/core/client/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,14 +96,16 @@ mod tests {
assert_eq!(t.expected_keys.len(), t.event.attributes.len());
for (i, e) in t.event.attributes.iter().enumerate() {
assert_eq!(
e.key, t.expected_keys[i],
e.key_str().unwrap(),
t.expected_keys[i],
"key mismatch for {:?}",
t.event_kind
);
}
for (i, e) in t.event.attributes.iter().enumerate() {
assert_eq!(
e.value, t.expected_values[i],
e.value_str().unwrap(),
t.expected_values[i],
"value mismatch for {:?}",
t.event_kind
);
Expand Down

0 comments on commit 931b99c

Please sign in to comment.