Skip to content

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

v2.13.0

01 May 23:42
Compare
Choose a tag to compare
  • bump up cli/ember/ember-data to version 2.13
  • switching to eslint
  • big time test refactoring
    • use async/await
    • rename tests groupings to behaviours

v2.12.5

01 May 23:44
Compare
Choose a tag to compare
  • moving to babel6 and fixing issues associated with that

v2.12.4

25 Apr 17:03
Compare
Choose a tag to compare

upgrades for ember-cli 2.13-beta and babel 6

v2.12.3

06 Apr 20:00
Compare
Choose a tag to compare

moves mockjax out of bower into npm packages #281

v2.12.2

23 Mar 11:34
Compare
Choose a tag to compare
  • fixes newer babel rejecting import syntax I was using in scenario.js #278

v2.12.1

22 Mar 12:05
Compare
Choose a tag to compare
  • move ember-cli-babel to dependencies #277

v2.12.0

18 Mar 15:12
Compare
Choose a tag to compare
  • bumping up ember/ember-data to 2.12
  • move last version to check for ember-try at 2.11
  • if you are using model fragments you need to be at 2.11+ as well

v2.11.7

14 Mar 14:32
Compare
Choose a tag to compare
  • fix for using factory-guy for testing in add-ons #276

v2.11.6

16 Feb 23:35
Compare
Choose a tag to compare
  • still trying to get the prod build to remove factory guy ( unless you need it for scenarios). maybe I got it this time?

v2.11.5

02 Feb 10:23
Compare
Choose a tag to compare
  • added better error message when forgetting to needs a transform in a unit test #273

Commonly in a unit test you will forget to needs everything you "need" like transforms

import {mockFindAll, mockSetup, mockTeardown, manualSetup} from 'ember-data-factory-guy';
import {moduleFor, test} from 'ember-qunit';

moduleFor('route:profiles', 'Unit | forgetting to needs transform', {
  beforeEach() {
    manualSetup(this.container);
  },

  afterEach() {
    mockTeardown();
  },

  needs: [
    'model:profile',
//    'transform:just-a-string'  ( it's common to forget this needs ) 
//                               ( but the profile model uses this transform )   
  ]
});

test('profiles', function(assert) {
  // this will barf because you forgot to needs a particular transform (just-a-string) 
  // that the profile model needs, but now with this version of FactoryGuy you will 
  // get a friendly message repeating pretty much what I just said in this comment
   mockFindAll('profile', 2)  })