3 changed files with 30 additions and 1 deletions
@ -0,0 +1,8 @@ |
|||
language: node_js |
|||
node_js: |
|||
- '8' |
|||
script: npm test |
|||
after_success: npm run coverage |
|||
notifications: |
|||
email: |
|||
on_success: never |
@ -0,0 +1,17 @@ |
|||
import test from 'ava'; |
|||
import dogeSeed from '..'; |
|||
|
|||
test('Seed phrases contain the words "much", "such" and "very"', t => { |
|||
const words = [...new Set( |
|||
new Array(1000) |
|||
.fill() |
|||
.map(dogeSeed) |
|||
.map(seedPhrase => [seedPhrase.split(' ')[0], seedPhrase.split(' ')[2]]) |
|||
.reduce((a, b) => a.concat(b), []) |
|||
)]; |
|||
|
|||
t.is(words.length, 3); |
|||
t.true(words.includes('much')); |
|||
t.true(words.includes('such')); |
|||
t.true(words.includes('very')); |
|||
}); |
Loading…
Reference in new issue