Skip to content
This repository has been archived by the owner on Nov 14, 2022. It is now read-only.

Commit

Permalink
chore(test): fix node bin not found on travis.
Browse files Browse the repository at this point in the history
  • Loading branch information
Markus Tacker committed Dec 6, 2016
1 parent 14c19fd commit 94bcc22
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions test/hook.spec.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
'use strict'

/* global describe, it */
/* global describe, it, process */

const expect = require('chai').expect
const childProcess = require('child_process')

describe('validate-commit-email', () => {
it('should exit the process with 1 on invalid email', done => {
const env = {
'GIT_AUTHOR_EMAIL': 'john.doe@example.com'
'GIT_AUTHOR_EMAIL': 'john.doe@example.com',
PATH: process.env.PATH
}
try {
childProcess.execSync('node index.js @acme.com$', {env})
Expand All @@ -20,7 +21,8 @@ describe('validate-commit-email', () => {
})
it('should exit the process with 0 on valid email', () => {
const env = {
'GIT_AUTHOR_EMAIL': 'john.doe@example.com'
'GIT_AUTHOR_EMAIL': 'john.doe@example.com',
PATH: process.env.PATH
}
childProcess.execSync('node index.js @example.com$', {env})
})
Expand Down

0 comments on commit 94bcc22

Please sign in to comment.