mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Upgrade Ember to 1.1.2
This commit is contained in:
@@ -17,7 +17,7 @@ asyncTestDiscourse('find', function() {
|
||||
});
|
||||
|
||||
asyncTestDiscourse('generateMasterKey', function() {
|
||||
this.stub(Discourse, 'ajax').returns(Ember.RSVP.resolve([]));
|
||||
this.stub(Discourse, 'ajax').returns(Ember.RSVP.resolve({api_key: {}}));
|
||||
Discourse.ApiKey.generateMasterKey().then(function() {
|
||||
start();
|
||||
ok(Discourse.ajax.calledWith("/admin/api/key", {type: 'POST'}), "it POSTs to create a master key");
|
||||
|
||||
@@ -14,7 +14,7 @@ test("without selectedPosts", function () {
|
||||
});
|
||||
|
||||
test("with some selectedPosts", function() {
|
||||
var testObj = buildTestObj({ selectedPosts: [Discourse.Post.create()] });
|
||||
var testObj = buildTestObj({ selectedPosts: [Discourse.Post.create({id: 123})] });
|
||||
equal(testObj.get('selectedPostsCount'), 1, "It returns the amount of posts");
|
||||
});
|
||||
|
||||
|
||||
5
test/javascripts/models/email_log_test.js
Normal file
5
test/javascripts/models/email_log_test.js
Normal file
@@ -0,0 +1,5 @@
|
||||
module("Discourse.EmailLog");
|
||||
|
||||
test("create", function() {
|
||||
ok(Discourse.EmailLog.create(), "it can be created without arguments");
|
||||
});
|
||||
5
test/javascripts/models/invite_test.js
Normal file
5
test/javascripts/models/invite_test.js
Normal file
@@ -0,0 +1,5 @@
|
||||
module("Discourse.Invite");
|
||||
|
||||
test("create", function() {
|
||||
ok(Discourse.Invite.create(), "it can be created without arguments");
|
||||
});
|
||||
5
test/javascripts/models/notification_test.js
Normal file
5
test/javascripts/models/notification_test.js
Normal file
@@ -0,0 +1,5 @@
|
||||
module("Discourse.Notification");
|
||||
|
||||
test("create", function() {
|
||||
ok(Discourse.Notification.create(), "it can be created without arguments");
|
||||
});
|
||||
@@ -11,6 +11,10 @@ var buildStream = function(id, stream) {
|
||||
|
||||
var participant = {username: 'eviltrout'};
|
||||
|
||||
test('create', function() {
|
||||
ok(Discourse.PostStream.create(), 'it can be created with no parameters');
|
||||
});
|
||||
|
||||
test('defaults', function() {
|
||||
var postStream = buildStream(1234);
|
||||
blank(postStream.get('posts'), "there are no posts in a stream by default");
|
||||
|
||||
@@ -1,6 +1,10 @@
|
||||
module("Discourse.Site");
|
||||
|
||||
test('instance', function(){
|
||||
test('create', function() {
|
||||
ok(Discourse.Site.create(), 'it can create with no parameters');
|
||||
});
|
||||
|
||||
test('instance', function() {
|
||||
|
||||
var site = Discourse.Site.current();
|
||||
|
||||
@@ -32,5 +36,4 @@ test('create categories', function() {
|
||||
present(subcategory, "it loaded the subcategory");
|
||||
equal(subcategory.get('parentCategory'), parent, "it has associated the child with the parent");
|
||||
|
||||
|
||||
});
|
||||
5
test/javascripts/models/staff_action_log_test.js
Normal file
5
test/javascripts/models/staff_action_log_test.js
Normal file
@@ -0,0 +1,5 @@
|
||||
module("Discourse.StaffActionLog");
|
||||
|
||||
test("create", function() {
|
||||
ok(Discourse.StaffActionLog.create(), "it can be created without arguments");
|
||||
});
|
||||
Reference in New Issue
Block a user