@@ -41,22 +41,26 @@ a8 = a8.read();
41
41
42
42
if ( ! common . hasFipsCrypto ) {
43
43
cryptoType = 'md5' ;
44
- digest = 'latin1'
44
+ digest = 'latin1' ;
45
45
const a0 = crypto . createHash ( cryptoType ) . update ( 'Test123' ) . digest ( digest ) ;
46
46
assert . strictEqual (
47
47
a0 ,
48
48
'h\u00ea\u00cb\u0097\u00d8o\fF!\u00fa+\u000e\u0017\u00ca\u00bd\u008c' ,
49
- `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash value. `
49
+ `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash`
50
50
) ;
51
51
}
52
52
cryptoType = 'md5' ;
53
53
digest = 'hex' ;
54
- assert . strictEqual ( a1 , '8308651804facb7b9af8ffc53a33a22d6a1c8ac2' ,
55
- `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash value.` ) ;
54
+ assert . strictEqual (
55
+ a1 ,
56
+ '8308651804facb7b9af8ffc53a33a22d6a1c8ac2' ,
57
+ `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash` ) ;
56
58
cryptoType = 'sha256' ;
57
59
digest = 'base64' ;
58
- assert . strictEqual ( a2 , '2bX1jws4GYKTlxhloUB09Z66PoJZW+y+hq5R8dnx9l4=' ,
59
- `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash value.` ) ;
60
+ assert . strictEqual (
61
+ a2 ,
62
+ '2bX1jws4GYKTlxhloUB09Z66PoJZW+y+hq5R8dnx9l4=' ,
63
+ `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash` ) ;
60
64
cryptoType = 'sha512' ;
61
65
digest = 'latin1' ;
62
66
assert . deepStrictEqual (
@@ -68,13 +72,13 @@ assert.deepStrictEqual(
68
72
'\u00d7\u00d6\u00a2\u00a8\u0085\u00e3<\u0083\u009c\u0093' +
69
73
'\u00c2\u0006\u00da0\u00a1\u00879(G\u00ed\'' ,
70
74
'latin1' ) ,
71
- `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash value. ` ) ;
75
+ `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash` ) ;
72
76
cryptoType = 'sha1' ;
73
77
digest = 'hex' ;
74
78
assert . deepStrictEqual (
75
79
a4 ,
76
80
Buffer . from ( '8308651804facb7b9af8ffc53a33a22d6a1c8ac2' , 'hex' ) ,
77
- `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash value. `
81
+ `${ cryptoType } with ${ digest } digest failed to evaluate to expected hash`
78
82
) ;
79
83
80
84
// stream interface should produce the same result.
0 commit comments