Skip to content

Commit

Permalink
test(action-code): concat two ActionCodes
Browse files Browse the repository at this point in the history
  • Loading branch information
EdJoPaTo committed Sep 16, 2018
1 parent 04c5c37 commit 2e017b2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions action-code.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,10 @@ test('concat an ActionCode', t => {
t.deepEqual(ActionCode.concat('b', new ActionCode(/(.+)/i)).get(), /^b:(.+)$/i)
})

test('concat two ActionCodes', t => {
t.is(ActionCode.concat(new ActionCode('main'), new ActionCode('a')).get(), 'a')
})

test('regex', t => {
t.deepEqual(new ActionCode(/(.+)/).get(), /^(.+)$/)
t.deepEqual(new ActionCode(/(.+)/i).get(), /^(.+)$/i)
Expand Down

0 comments on commit 2e017b2

Please sign in to comment.