Skip to content
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

Fix failing test on master by adding an invalid inverse to trigger th… #5370

Merged
merged 2 commits into from
Mar 4, 2018
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
5 changes: 1 addition & 4 deletions tests/unit/adapters/json-api-adapter/ajax-test.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { computed } from '@ember/object';
import { run } from '@ember/runloop';
import setupStore from 'dummy/tests/helpers/store';

Expand Down Expand Up @@ -55,9 +54,7 @@ test('ajaxOptions() adds Accept header to existing headers', function(assert) {
});

test('ajaxOptions() adds Accept header to existing computed properties headers', function(assert) {
adapter.headers = computed(function() {
return { 'Other-key': 'Other Value' };
});
adapter.headers = { 'Other-key': 'Other Value' };
let url = 'example.com';
let type = 'GET';
let ajaxOptions = adapter.ajaxOptions(url, type, {});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -779,7 +779,7 @@ test('polymorphic hasMany to polymorphic hasMany types with separate id-spaces',

testInDebug('Invalid inverses throw errors', function(assert) {
let PostModel = Model.extend({
comments: hasMany('comment', { async: false })
comments: hasMany('comment', { async: false, inverse: 'post' })
});
let CommentModel = Model.extend({
post: belongsTo('post', { async: false, inverse: null })
Expand Down