Skip to content

Instantly share code, notes, and snippets.

@jhartikainen
Created June 12, 2016 12:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jhartikainen/84dad654196619b5460fd08cb234f031 to your computer and use it in GitHub Desktop.
Save jhartikainen/84dad654196619b5460fd08cb234f031 to your computer and use it in GitHub Desktop.
Parametrized test with Mocha example
describe('Something', function() {
var values = ['a', 'b', 'c'];
values.forEach(function(val) {
it('should do something with ' + val + ' in this test', function() {
assert.equal(foo(), val);
});
})
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment