Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/data.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ var Factory = require('rosie').Factory;
var faker = require('@faker-js/faker');

module.exports = new Factory()
.attr('name', () => faker.name.findName())
.attr('name', () => faker.person.findName())
.attr('email', () => faker.internet.email());
```

Expand Down Expand Up @@ -271,7 +271,7 @@ module.exports = new Factory((buildObj) => {
input: { ...buildObj },
}
})
.attr('name', () => faker.name.findName())
.attr('name', () => faker.person.findName())
.attr('email', () => faker.internet.email());
```

Expand Down
2 changes: 1 addition & 1 deletion docs/helpers/ApiDataFactory.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ const { faker } = require('@faker-js/faker');

module.exports = new Factory()
// no need to set id, it will be set by REST API
.attr('author', () => faker.name.findName())
.attr('author', () => faker.person.findName())
.attr('title', () => faker.lorem.sentence())
.attr('body', () => faker.lorem.paragraph());
```
Expand Down
2 changes: 1 addition & 1 deletion docs/helpers/GraphQLDataFactory.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ module.exports = new Factory((buildObj) => ({
input: { ...buildObj },
}))
// 'attr'-id can be left out depending on the GraphQl resolvers
.attr('name', () => faker.name.findName())
.attr('name', () => faker.person.findName())
.attr('email', () => faker.interact.email())
```

Expand Down
2 changes: 1 addition & 1 deletion lib/helper/ApiDataFactory.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ const REST = require('./REST')
*
* module.exports = new Factory()
* // no need to set id, it will be set by REST API
* .attr('author', () => faker.name.findName())
* .attr('author', () => faker.person.findName())
* .attr('title', () => faker.lorem.sentence())
* .attr('body', () => faker.lorem.paragraph());
* ```
Expand Down
2 changes: 1 addition & 1 deletion lib/helper/GraphQLDataFactory.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ const GraphQL = require('./GraphQL')
* input: { ...buildObj },
* }))
* // 'attr'-id can be left out depending on the GraphQl resolvers
* .attr('name', () => faker.name.findName())
* .attr('name', () => faker.person.findName())
* .attr('email', () => faker.interact.email())
* ```
* For more options see [rosie documentation](https://github.com/rosiejs/rosie).
Expand Down
2 changes: 1 addition & 1 deletion test/data/graphql/users_factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ const { faker } = require('@faker-js/faker');
module.exports = new Factory(function (buildObject) {
this.input = { ...buildObject };
})
.attr('name', () => faker.name.fullName())
.attr('name', () => faker.person.fullName())
.attr('email', () => faker.internet.email());
2 changes: 1 addition & 1 deletion test/data/rest/posts_factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ const { Factory } = require('rosie');
const { faker } = require('@faker-js/faker');

module.exports = new Factory()
.attr('author', () => faker.name.fullName())
.attr('author', () => faker.person.fullName())
.attr('title', () => faker.lorem.sentence())
.attr('body', () => faker.lorem.paragraph());
Loading