Skip to content

chore(package): update ember-cli-mirage to version 0.2.1 #374

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
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
7 changes: 5 additions & 2 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,11 @@
"moment": ">= 2.8.0",
"moment-timezone": ">= 0.1.0",
"normalize-css": "~3.0.3",
"pretender": "~0.10.1",
"pretender": "~1.1.0",
"lodash": "~3.7.0",
"Faker": "~3.0.0"
"Faker": "~3.1.0"
},
"resolutions": {
"FakeXMLHttpRequest": "^1.4.0"
}
}
22 changes: 22 additions & 0 deletions mirage/config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
export default function() {

// These comments are here to help you get started. Feel free to delete them.

// Config (with defaults).
//
// Note: these only affect routes defined *after* them!

// this.urlPrefix = ''; // make this `http://localhost:8080`, for example, if your API is on a different server
// this.namespace = ''; // make this `api`, for example, if your API is namespaced
// this.timing = 400; // delay for each request, automatically set to 0 during testing

// Shorthand cheatsheet:

// this.get('/posts');
// this.post('/posts');
// this.get('/posts/:id');
// this.put('/posts/:id'); // or this.patch
// this.del('/posts/:id');

// http://www.ember-cli-mirage.com/docs/v0.2.x/shorthands/
}
9 changes: 9 additions & 0 deletions mirage/scenarios/default.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
export default function(/* server */) {

// Seed your development database using your factories.
// This data will not be loaded in your tests.

// Make sure to define a factory for each model you want to create.

// server.createList('post', 10);
}
4 changes: 4 additions & 0 deletions mirage/serializers/application.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import { JSONAPISerializer } from 'ember-cli-mirage';

export default JSONAPISerializer.extend({
});
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"ember-cli-htmlbars-inline-precompile": "^0.3.1",
"ember-cli-ic-ajax": "1.0.0",
"ember-cli-inject-live-reload": "^1.3.1",
"ember-cli-mirage": "0.1.13",
"ember-cli-mirage": "0.2.1",
"ember-cli-moment-shim": "2.0.0",
"ember-cli-qunit": "^2.0.0",
"ember-cli-release": "0.2.8",
Expand Down
1 change: 1 addition & 0 deletions tests/helpers/destroy-app.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ import Ember from 'ember';

export default function destroyApp(application) {
Ember.run(application, 'destroy');
server.shutdown();
}