Skip to content

Commit

Permalink
Merge pull request #538 from APIs-guru/master
Browse files Browse the repository at this point in the history
[test] Add test for setLocale function added in #488
  • Loading branch information
Marak authored Sep 9, 2017
2 parents b198dda + 54aab21 commit 23c05db
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion test/locales.unit.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,15 @@ if (typeof module !== 'undefined') {

// TODO: make some tests for getting / setting locales

// Remark: actual use of locales functionality is currently tested in all.functional.js test
// Remark: actual use of locales functionality is currently tested in all.functional.js test

describe("locale", function () {
describe("setLocale()", function () {
it("setLocale() changes faker.locale", function () {
for(var locale in faker.locales) {
faker.setLocale(locale)
assert.equal(faker.locale, locale);
}
});
});
});

0 comments on commit 23c05db

Please sign in to comment.