Skip to content

Commit

Permalink
add a test case
Browse files Browse the repository at this point in the history
  • Loading branch information
hidetatz committed Mar 21, 2022
1 parent ade12ac commit 367c400
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions cpu_compression_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,15 @@ func TestCPU_Decompress(t *testing.T) {
compressed: 0b1000_01101_01111_10,
expected: 0b0000000_01111_00000_000_01101_0110011,
},
//"c.add": {},
"c.add": {
compressed: 0b1001_01101_01111_10,
expected: 0b0000000_01111_01101_000_01101_0110011,
},
}

for name, tc := range tests {
tc := tc
t.Run(name, func(t *testing.T) {
t.Parallel()
cpu := &CPU{} // Decompression does not require any CPu state
got, gotExcp := cpu.Decompress(tc.compressed)
if gotExcp != tc.expectedExcp {
Expand Down

0 comments on commit 367c400

Please sign in to comment.