@@ -72,13 +72,13 @@ test_ecdsaRecover =
72
72
where
73
73
test messageHash v r s result =
74
74
testCase (Text. unpack name) $ do
75
- let expect = InternalBytes. asPattern internalBytesSort (BS. pack result)
75
+ let expect = InternalBytes. asPattern bytesSort (BS. pack result)
76
76
actual <-
77
77
ecdsaRecoverKrypto
78
- (InternalBytes. asInternal internalBytesSort (BS. pack messageHash))
78
+ (InternalBytes. asInternal bytesSort (BS. pack messageHash))
79
79
(Test.Int. asInternal v)
80
- (InternalBytes. asInternal internalBytesSort (BS. pack r))
81
- (InternalBytes. asInternal internalBytesSort (BS. pack s))
80
+ (InternalBytes. asInternal bytesSort (BS. pack r))
81
+ (InternalBytes. asInternal bytesSort (BS. pack s))
82
82
& evaluate " KRYPTO.ecdsaRecover"
83
83
assertEqual " " expect actual
84
84
where
@@ -104,13 +104,13 @@ test_secp256k1EcdsaRecover =
104
104
where
105
105
test messageHash v r s result =
106
106
testCase (Text. unpack name) $ do
107
- let expect = String . asPattern stringSort result
107
+ let expect = InternalBytes . asPattern bytesSort ( BS. pack result)
108
108
actual <-
109
109
ecdsaRecoverKrypto
110
- (String . asInternal stringSort messageHash)
110
+ (InternalBytes . asInternal bytesSort ( BS. pack messageHash) )
111
111
(Test.Int. asInternal v)
112
- (String . asInternal stringSort r )
113
- (String . asInternal stringSort s )
112
+ (InternalBytes . asInternal bytesSort ( BS. pack r) )
113
+ (InternalBytes . asInternal bytesSort ( BS. pack s) )
114
114
& evaluate " SECP256K1.ecdsaRecover"
115
115
assertEqual " " expect actual
116
116
where
@@ -133,7 +133,7 @@ test_keccak256 =
133
133
testCase (show input) $ do
134
134
let expect = String. asPattern stringSort result
135
135
actual <-
136
- keccak256Krypto (String . asInternal stringSort input)
136
+ keccak256Krypto (InternalBytes . asInternal bytesSort ( BS. pack input) )
137
137
& evaluate " KRYPTO.keccak256"
138
138
assertEqual " " expect actual
139
139
@@ -152,7 +152,7 @@ test_hashKeccak256 =
152
152
testCase (show input) $ do
153
153
let expect = String. asPattern stringSort result
154
154
actual <-
155
- keccak256Krypto (String . asInternal stringSort input)
155
+ keccak256Krypto (InternalBytes . asInternal bytesSort ( BS. pack input) )
156
156
& evaluate " HASH.keccak256"
157
157
assertEqual " " expect actual
158
158
@@ -171,7 +171,7 @@ test_sha256 =
171
171
testCase (show input) $ do
172
172
let expect = String. asPattern stringSort result
173
173
actual <-
174
- sha256Krypto (String . asInternal stringSort input)
174
+ sha256Krypto (InternalBytes . asInternal bytesSort ( BS. pack input) )
175
175
& evaluate " KRYPTO.sha256"
176
176
assertEqual " " expect actual
177
177
@@ -190,7 +190,7 @@ test_hashSha256 =
190
190
testCase (show input) $ do
191
191
let expect = String. asPattern stringSort result
192
192
actual <-
193
- sha256Krypto (String . asInternal stringSort input)
193
+ sha256Krypto (InternalBytes . asInternal bytesSort ( BS. pack input) )
194
194
& evaluate " HASH.sha256"
195
195
assertEqual " " expect actual
196
196
@@ -209,7 +209,7 @@ test_sha3256 =
209
209
testCase (show input) $ do
210
210
let expect = String. asPattern stringSort result
211
211
actual <-
212
- sha3256Krypto (String . asInternal stringSort input)
212
+ sha3256Krypto (InternalBytes . asInternal bytesSort ( BS. pack input) )
213
213
& evaluate " KRYPTO.sha3256"
214
214
assertEqual " " expect actual
215
215
@@ -228,7 +228,7 @@ test_hashSha3_256 =
228
228
testCase (show input) $ do
229
229
let expect = String. asPattern stringSort result
230
230
actual <-
231
- sha3256Krypto (String . asInternal stringSort input)
231
+ sha3256Krypto (InternalBytes . asInternal bytesSort ( BS. pack input) )
232
232
& evaluate " HASH.sha3_256"
233
233
assertEqual " " expect actual
234
234
@@ -253,7 +253,7 @@ test_ripemd160 =
253
253
testCase (show input) $ do
254
254
let expect = String. asPattern stringSort result
255
255
actual <-
256
- ripemd160Krypto (String . asInternal stringSort input)
256
+ ripemd160Krypto (InternalBytes . asInternal bytesSort ( BS. pack input) )
257
257
& evaluate " KRYPTO.ripemd160"
258
258
assertEqual " " expect actual
259
259
@@ -278,7 +278,7 @@ test_hashRipemd160 =
278
278
testCase (show input) $ do
279
279
let expect = String. asPattern stringSort result
280
280
actual <-
281
- ripemd160Krypto (String . asInternal stringSort input)
281
+ ripemd160Krypto (InternalBytes . asInternal bytesSort ( BS. pack input) )
282
282
& evaluate " HASH.ripemd160"
283
283
assertEqual " " expect actual
284
284
0 commit comments