aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTyler <[email protected]>2018-10-20 19:48:34 -0700
committerTyler <[email protected]>2018-10-20 19:48:34 -0700
commit031ad231ba6e88e8c5f40c5a8b62d2faa3fb7b61 (patch)
tree437e9701bad8e75907bfb475349f691e61ef3594
parent4b76433c2477e0d4e9441764b5200e25b3221fd6 (diff)
parentb78fdff29d5c6c3318948c2c44c7903eed55ce4c (diff)
downloadfaker-031ad231ba6e88e8c5f40c5a8b62d2faa3fb7b61.tar.xz
faker-031ad231ba6e88e8c5f40c5a8b62d2faa3fb7b61.zip
Merge branch 'master' of https://github.com/tylerreichle/faker.js into add-vehicle
-rw-r--r--build/src/docs.md5
-rw-r--r--lib/company.js2
-rw-r--r--test/company.unit.js10
3 files changed, 11 insertions, 6 deletions
diff --git a/build/src/docs.md b/build/src/docs.md
index 28e323fe..e173c05e 100644
--- a/build/src/docs.md
+++ b/build/src/docs.md
@@ -130,6 +130,11 @@ See: https://github.com/pateketrueke/json-schema-faker/
Run faker generators from Command Line.
See: https://github.com/lestoni/faker-cli
+### Mocker data generator
+
+Minimal JSON data generator, fakerJs is one of the providers.
+See: https://github.com/danibram/mocker-data-generator
+
**Want to see your project added here? Let us know!**
### Meteor
diff --git a/lib/company.js b/lib/company.js
index ebb436dd..d16689e2 100644
--- a/lib/company.js
+++ b/lib/company.js
@@ -62,7 +62,7 @@ var Company = function (faker) {
* @method faker.company.bs
*/
this.bs = function () {
- return f('{{company.bsAdjective}} {{company.bsBuzz}} {{company.bsNoun}}');
+ return f('{{company.bsBuzz}} {{company.bsAdjective}} {{company.bsNoun}}');
}
/**
diff --git a/test/company.unit.js b/test/company.unit.js
index f863d83d..06292b35 100644
--- a/test/company.unit.js
+++ b/test/company.unit.js
@@ -79,22 +79,22 @@ describe("company.js", function () {
});
describe("bs()", function () {
- it("returns phrase comprising of a BS adjective, buzz, and noun", function () {
+ it("returns phrase comprising of a BS buzz, adjective, and noun", function () {
sinon.spy(faker.random, 'arrayElement');
- sinon.spy(faker.company, 'bsAdjective');
sinon.spy(faker.company, 'bsBuzz');
+ sinon.spy(faker.company, 'bsAdjective');
sinon.spy(faker.company, 'bsNoun');
var bs = faker.company.bs();
assert.ok(typeof bs === 'string');
assert.ok(faker.random.arrayElement.calledThrice);
- assert.ok(faker.company.bsAdjective.calledOnce);
assert.ok(faker.company.bsBuzz.calledOnce);
+ assert.ok(faker.company.bsAdjective.calledOnce);
assert.ok(faker.company.bsNoun.calledOnce);
- faker.random.arrayElement.restore();
- faker.company.bsAdjective.restore();
+ faker.random.arrayElement.restore();
faker.company.bsBuzz.restore();
+ faker.company.bsAdjective.restore();
faker.company.bsNoun.restore();
});
});