Skip to content

Commit

Permalink
Bless coverage tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Swatinem committed Aug 22, 2023
1 parent ffafc9e commit 7f985c4
Show file tree
Hide file tree
Showing 46 changed files with 1,219 additions and 299 deletions.
9 changes: 6 additions & 3 deletions tests/coverage-map/if.cov-map
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
Function name: if::main
Raw bytes (28): 0x[01, 01, 02, 01, 05, 05, 02, 04, 01, 03, 01, 02, 0c, 05, 02, 0d, 02, 06, 02, 02, 06, 00, 07, 07, 01, 05, 01, 02]
Raw bytes (35): 0x[01, 01, 02, 01, 05, 05, 02, 05, 01, 03, 01, 02, 0c, 20, 05, 02, 02, 08, 00, 0c, 05, 00, 0d, 02, 06, 02, 02, 06, 00, 07, 07, 01, 05, 01, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 2
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Expression(0, Sub)
Number of file 0 mappings: 4
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 3, 1) to (start + 2, 12)
- Code(Counter(1)) at (prev + 2, 13) to (start + 2, 6)
- Branch at (prev + 2, 8) to (start + 0, 12)
true = c1
false = (c0 - c1)
- Code(Counter(1)) at (prev + 0, 13) to (start + 2, 6)
- Code(Expression(0, Sub)) at (prev + 2, 6) to (start + 0, 7)
= (c0 - c1)
- Code(Expression(1, Add)) at (prev + 1, 5) to (start + 1, 2)
Expand Down
43 changes: 28 additions & 15 deletions tests/coverage-map/status-quo/async2.cov-map
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,18 @@ Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 20, 1) to (start + 0, 23)

Function name: async2::async_func::{closure#0}
Raw bytes (28): 0x[01, 01, 02, 01, 05, 05, 02, 04, 01, 14, 17, 03, 09, 05, 03, 0a, 02, 06, 02, 02, 06, 00, 07, 07, 01, 01, 00, 02]
Raw bytes (35): 0x[01, 01, 02, 01, 05, 05, 02, 05, 01, 14, 17, 03, 09, 20, 05, 02, 03, 08, 00, 09, 05, 00, 0a, 02, 06, 02, 02, 06, 00, 07, 07, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 2
- expression 0 operands: lhs = Counter(0), rhs = Counter(1)
- expression 1 operands: lhs = Counter(1), rhs = Expression(0, Sub)
Number of file 0 mappings: 4
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 20, 23) to (start + 3, 9)
- Code(Counter(1)) at (prev + 3, 10) to (start + 2, 6)
- Branch at (prev + 3, 8) to (start + 0, 9)
true = c1
false = (c0 - c1)
- Code(Counter(1)) at (prev + 0, 10) to (start + 2, 6)
- Code(Expression(0, Sub)) at (prev + 2, 6) to (start + 0, 7)
= (c0 - c1)
- Code(Expression(1, Add)) at (prev + 1, 1) to (start + 0, 2)
Expand All @@ -38,7 +41,7 @@ Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 31, 36) to (start + 2, 2)

Function name: async2::executor::block_on::<async2::async_func::{closure#0}>
Raw bytes (44): 0x[01, 01, 05, 0b, 05, 01, 05, 01, 05, 02, 00, 02, 00, 06, 01, 33, 05, 0a, 36, 02, 0d, 20, 00, 23, 0b, 00, 27, 00, 49, 0f, 01, 17, 00, 1a, 05, 01, 0e, 00, 0f, 13, 02, 05, 00, 06]
Raw bytes (51): 0x[01, 01, 05, 0b, 05, 01, 05, 01, 05, 02, 00, 02, 00, 07, 01, 33, 05, 0a, 36, 20, 05, 02, 0d, 14, 00, 24, 02, 00, 20, 00, 23, 0b, 00, 27, 00, 49, 0f, 01, 17, 00, 1a, 05, 01, 0e, 00, 0f, 13, 02, 05, 00, 06]
Number of files: 1
- file 0 => global file 1
Number of expressions: 5
Expand All @@ -47,9 +50,12 @@ Number of expressions: 5
- expression 2 operands: lhs = Counter(0), rhs = Counter(1)
- expression 3 operands: lhs = Expression(0, Sub), rhs = Zero
- expression 4 operands: lhs = Expression(0, Sub), rhs = Zero
Number of file 0 mappings: 6
Number of file 0 mappings: 7
- Code(Counter(0)) at (prev + 51, 5) to (start + 10, 54)
- Code(Expression(0, Sub)) at (prev + 13, 32) to (start + 0, 35)
- Branch at (prev + 13, 20) to (start + 0, 36)
true = c1
false = ((c0 + c1) - c1)
- Code(Expression(0, Sub)) at (prev + 0, 32) to (start + 0, 35)
= ((c0 + c1) - c1)
- Code(Expression(2, Add)) at (prev + 0, 39) to (start + 0, 73)
= (c0 + c1)
Expand All @@ -60,7 +66,7 @@ Number of file 0 mappings: 6
= (((c0 + c1) - c1) + Zero)

Function name: async2::executor::block_on::<async2::async_func_just_println::{closure#0}>
Raw bytes (44): 0x[01, 01, 05, 0b, 05, 01, 05, 01, 05, 02, 00, 02, 00, 06, 01, 33, 05, 0a, 36, 02, 0d, 20, 00, 23, 0b, 00, 27, 00, 49, 0f, 01, 17, 00, 1a, 05, 01, 0e, 00, 0f, 13, 02, 05, 00, 06]
Raw bytes (51): 0x[01, 01, 05, 0b, 05, 01, 05, 01, 05, 02, 00, 02, 00, 07, 01, 33, 05, 0a, 36, 20, 05, 02, 0d, 14, 00, 24, 02, 00, 20, 00, 23, 0b, 00, 27, 00, 49, 0f, 01, 17, 00, 1a, 05, 01, 0e, 00, 0f, 13, 02, 05, 00, 06]
Number of files: 1
- file 0 => global file 1
Number of expressions: 5
Expand All @@ -69,9 +75,12 @@ Number of expressions: 5
- expression 2 operands: lhs = Counter(0), rhs = Counter(1)
- expression 3 operands: lhs = Expression(0, Sub), rhs = Zero
- expression 4 operands: lhs = Expression(0, Sub), rhs = Zero
Number of file 0 mappings: 6
Number of file 0 mappings: 7
- Code(Counter(0)) at (prev + 51, 5) to (start + 10, 54)
- Code(Expression(0, Sub)) at (prev + 13, 32) to (start + 0, 35)
- Branch at (prev + 13, 20) to (start + 0, 36)
true = c1
false = ((c0 + c1) - c1)
- Code(Expression(0, Sub)) at (prev + 0, 32) to (start + 0, 35)
= ((c0 + c1) - c1)
- Code(Expression(2, Add)) at (prev + 0, 39) to (start + 0, 73)
= (c0 + c1)
Expand Down Expand Up @@ -122,15 +131,19 @@ Number of file 0 mappings: 1
- Code(Counter(0)) at (prev + 35, 1) to (start + 7, 2)

Function name: async2::non_async_func
Raw bytes (26): 0x[01, 01, 01, 05, 00, 04, 01, 09, 01, 03, 09, 05, 03, 0a, 02, 06, 00, 02, 06, 00, 07, 03, 01, 01, 00, 02]
Raw bytes (35): 0x[01, 01, 02, 00, 00, 05, 00, 05, 01, 09, 01, 03, 09, 20, 05, 02, 03, 08, 00, 09, 05, 00, 0a, 02, 06, 00, 02, 06, 00, 07, 07, 01, 01, 00, 02]
Number of files: 1
- file 0 => global file 1
Number of expressions: 1
- expression 0 operands: lhs = Counter(1), rhs = Zero
Number of file 0 mappings: 4
Number of expressions: 2
- expression 0 operands: lhs = Zero, rhs = Zero
- expression 1 operands: lhs = Counter(1), rhs = Zero
Number of file 0 mappings: 5
- Code(Counter(0)) at (prev + 9, 1) to (start + 3, 9)
- Code(Counter(1)) at (prev + 3, 10) to (start + 2, 6)
- Branch at (prev + 3, 8) to (start + 0, 9)
true = c1
false = (Zero - Zero)
- Code(Counter(1)) at (prev + 0, 10) to (start + 2, 6)
- Code(Zero) at (prev + 2, 6) to (start + 0, 7)
- Code(Expression(0, Add)) at (prev + 1, 1) to (start + 0, 2)
- Code(Expression(1, Add)) at (prev + 1, 1) to (start + 0, 2)
= (c1 + Zero)

Loading

0 comments on commit 7f985c4

Please sign in to comment.