|
|
@@ -16,13 +16,9 @@ describe( 'utils', () => {
|
|
|
expect( id2 ).to.be.a( 'string' ).to.not.equal( id1 ).to.not.equal( id3 );
|
|
|
expect( id3 ).to.be.a( 'string' ).to.not.equal( id1 ).to.not.equal( id2 );
|
|
|
|
|
|
- expect( id1[ 0 ] ).to.match( /[a-z]/ );
|
|
|
- expect( id2[ 0 ] ).to.match( /[a-z]/ );
|
|
|
- expect( id3[ 0 ] ).to.match( /[a-z]/ );
|
|
|
-
|
|
|
- expect( id1 ).to.have.length( 33 );
|
|
|
- expect( id2 ).to.have.length( 33 );
|
|
|
- expect( id3 ).to.have.length( 33 );
|
|
|
+ expect( id1 ).to.match( /^[a-z][a-z0-9]{32}$/ );
|
|
|
+ expect( id2 ).to.match( /^[a-z][a-z0-9]{32}$/ );
|
|
|
+ expect( id3 ).to.match( /^[a-z][a-z0-9]{32}$/ );
|
|
|
} );
|
|
|
} );
|
|
|
} );
|