Skip to content

Releases: adopted-ember-addons/ember-data-factory-guy

v2.13.21

04 Jan 17:16
Compare
Choose a tag to compare
  • fixing use of mockCreate when used with new model

This used to break with using json-api adapter/serializer

let user = makeNew('user')
mockCreate(user);

v2.13.20

17 Dec 20:00
Compare
Choose a tag to compare
  • fixing mockUpdate to only return data when return attrs are set
    • mockUpdate(user) was previously returning data in payload and clearing out previously set variables in the model
 let user = make('user');
 mockUpdate(user); // now returns null payload by default

v2.13.19

02 Dec 00:54
Compare
Choose a tag to compare

-fixes bug where type was being set incorrectly when returning models with mockFindAll or mockQuery #321 @gleseur

v2.13.18

30 Nov 15:15
Compare
Choose a tag to compare

v2.13.17

30 Nov 12:04
Compare
Choose a tag to compare
  • fixes pluralize deprecations #316 @krasnoukhov
  • Use assign from ember polyfills ( fixes phantomjs usage ) #317 @krasnoukhov
  • fixes creating model fragments manually in build/buildList/make/makeList and in belongsTo/hasMany factory methods
    • can now use make / makeList with fragments

Now, you can use make/makeList to manually make fragments for a model like this:

  let firstName = 'Joe',
      lastName  = 'Black',
      name      = make('name', {firstName: 'Joe', lastName: 'Black'}),
      employee  = make('employee', {name});
 
  employee.get('name').getProperties(['firstName', 'lastName'])) // => {firstName: 'Joe', lastName: 'Black'}

v2.13.16

18 Nov 19:36
Compare
Choose a tag to compare
  • fix willDestroy store override to ensure that original store.willDestroy is still used

v2.13.15

18 Nov 15:16
Compare
Choose a tag to compare
  • mockSetup and mockTeardown are no longer needed
    • factory guy now cleans up after itself when test is torn down.
    • if you want to set the logLevel or responseTime do so like this:
FactoryGuy.settings({logLevel: 1, responseTime: 100});

v2.13.14

10 Nov 12:45
Compare
Choose a tag to compare
  • WIP clean up variables in Factory Guy when store is destroyed to avoid memory leaks

v2.13.13

05 Nov 19:50
Compare
Choose a tag to compare
  • super duper extra sure I finally got this working with fastboot

v2.13.12

05 Nov 19:17
Compare
Choose a tag to compare
  • one more try at fix for building in fastboot environment #282
  • improved logging for mock requests
  • mockCreate can now be passed a newly created model
  let profile  = makeNew('profile'); 
  let mock   = mockCreate(profile);