padEnd
Fri May 21 2021 14:35:15 GMT+0000 (Coordinated Universal Time)
Saved by
@ejiwen
describe('Maestro', function() {
prefixMaestro = ['5018','5020','5038','6304'];
for (let length = 12; length <= 19; length++) {
for (let prefix = 0; prefix < prefixMaestro.length; prefix++){
(function(length, prefix){
it ('has a prefix of ' + prefixMaestro[prefix]+ ' and a length of ' +length, function(){
detectNetwork(prefixMaestro[prefix].padEnd(length,'0')).should.equal('Maestro')
});
})(length, prefix);
}
}
});
content_copyCOPY
Comments