Merge branch 'stable' into develop
This commit is contained in:
commit
4abc0c5988
5 changed files with 15 additions and 10 deletions
2
Gemfile
2
Gemfile
|
|
@ -86,7 +86,7 @@ gem "entypo-rails", "3.0.0.pre.rc2"
|
||||||
|
|
||||||
# JavaScript
|
# JavaScript
|
||||||
|
|
||||||
gem "backbone-on-rails", "1.1.2.1"
|
gem "backbone-on-rails", "1.2.0.0"
|
||||||
gem "handlebars_assets", "0.20.2"
|
gem "handlebars_assets", "0.20.2"
|
||||||
gem "jquery-rails", "4.0.4"
|
gem "jquery-rails", "4.0.4"
|
||||||
gem "jquery-ui-rails", "5.0.5"
|
gem "jquery-ui-rails", "5.0.5"
|
||||||
|
|
|
||||||
|
|
@ -60,7 +60,7 @@ GEM
|
||||||
autoprefixer-rails (5.2.1)
|
autoprefixer-rails (5.2.1)
|
||||||
execjs
|
execjs
|
||||||
json
|
json
|
||||||
backbone-on-rails (1.1.2.1)
|
backbone-on-rails (1.2.0.0)
|
||||||
eco
|
eco
|
||||||
ejs
|
ejs
|
||||||
jquery-rails
|
jquery-rails
|
||||||
|
|
@ -774,7 +774,7 @@ DEPENDENCIES
|
||||||
addressable (= 2.3.8)
|
addressable (= 2.3.8)
|
||||||
asset_sync (= 1.1.0)
|
asset_sync (= 1.1.0)
|
||||||
autoprefixer-rails (= 5.2.1)
|
autoprefixer-rails (= 5.2.1)
|
||||||
backbone-on-rails (= 1.1.2.1)
|
backbone-on-rails (= 1.2.0.0)
|
||||||
bootstrap-sass (= 3.3.5)
|
bootstrap-sass (= 3.3.5)
|
||||||
bootstrap-switch-rails (= 3.3.3)
|
bootstrap-switch-rails (= 3.3.3)
|
||||||
capybara (= 2.4.4)
|
capybara (= 2.4.4)
|
||||||
|
|
|
||||||
|
|
@ -132,7 +132,7 @@ app.Router = Backbone.Router.extend({
|
||||||
{tagText: decodeURIComponent(name).toLowerCase()}
|
{tagText: decodeURIComponent(name).toLowerCase()}
|
||||||
);
|
);
|
||||||
$("#author_info").prepend(followedTagsAction.render().el);
|
$("#author_info").prepend(followedTagsAction.render().el);
|
||||||
app.tags = new app.views.Tags({tagName: name});
|
app.tags = new app.views.Tags({hashtagName: name});
|
||||||
}
|
}
|
||||||
this._hideInactiveStreamLists();
|
this._hideInactiveStreamLists();
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,8 @@
|
||||||
// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPL-v3-or-Later
|
// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPL-v3-or-Later
|
||||||
|
|
||||||
app.views.Tags = Backbone.View.extend({
|
app.views.Tags = Backbone.View.extend({
|
||||||
|
initialize: function(opts) {
|
||||||
initialize: function() {
|
app.publisher.setText("#"+ opts.hashtagName + " ");
|
||||||
app.publisher.setText("#"+ this.tagName + " ");
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// @license-end
|
// @license-end
|
||||||
|
|
|
||||||
|
|
@ -60,13 +60,19 @@ describe("app.views.Feedback", function(){
|
||||||
});
|
});
|
||||||
|
|
||||||
it("allows for unliking a just-liked post", function(){
|
it("allows for unliking a just-liked post", function(){
|
||||||
var responseText = JSON.stringify({"author": this.userAttrs});
|
|
||||||
var ajax_success = { status: 201, responseText: responseText };
|
|
||||||
expect(this.link().text()).toContain(Diaspora.I18n.t("stream.like"));
|
expect(this.link().text()).toContain(Diaspora.I18n.t("stream.like"));
|
||||||
this.link().click();
|
this.link().click();
|
||||||
jasmine.Ajax.requests.mostRecent().respondWith(ajax_success);
|
jasmine.Ajax.requests.mostRecent().respondWith({
|
||||||
|
status: 201,
|
||||||
|
responseText: JSON.stringify({
|
||||||
|
id: 42,
|
||||||
|
guid: 42,
|
||||||
|
author: this.userAttrs
|
||||||
|
})
|
||||||
|
});
|
||||||
expect(this.link().text()).toContain(Diaspora.I18n.t("stream.unlike"));
|
expect(this.link().text()).toContain(Diaspora.I18n.t("stream.unlike"));
|
||||||
this.link().click();
|
this.link().click();
|
||||||
|
jasmine.Ajax.requests.mostRecent().respondWith({status: 204});
|
||||||
expect(this.link().text()).toContain(Diaspora.I18n.t("stream.like"));
|
expect(this.link().text()).toContain(Diaspora.I18n.t("stream.like"));
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue