Skip to content
Extraits de code Groupes Projets
Valider 16223d00 rédigé par Dennis Collinson's avatar Dennis Collinson
Parcourir les fichiers

change new publisher to public by default to make testing easier

parent 25f6df23
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -5,7 +5,7 @@ app.views.AspectsDropdown = app.views.Base.extend({ ...@@ -5,7 +5,7 @@ app.views.AspectsDropdown = app.views.Base.extend({
}, },
postRenderTemplate : function(){ postRenderTemplate : function(){
this.setVisibility({target : this.$("a[data-visibility='all-aspects']").first()}) this.setVisibility({target : this.$("a[data-visibility='public']").first()})
}, },
setVisibility : function(evt){ setVisibility : function(evt){
......
...@@ -122,7 +122,7 @@ When /^I select the mood "([^"]*)"$/ do |mood| ...@@ -122,7 +122,7 @@ When /^I select the mood "([^"]*)"$/ do |mood|
click_link mood click_link mood
end end
Then /^the post's mood should (?:still |)be "([^"]*)"$/ do |mood| Then /^the post's (?:default |)mood should (?:still |)be "([^"]*)"$/ do |mood|
assert_post_renders_with(mood) assert_post_renders_with(mood)
end end
......
...@@ -47,10 +47,11 @@ Feature: Creating a new post ...@@ -47,10 +47,11 @@ Feature: Creating a new post
And I upload a fixture picture with filename "button.gif" And I upload a fixture picture with filename "button.gif"
And I start the framing process And I start the framing process
#defaults to the prettiest mood
Then the post's default mood should be "Wallpaper"
Then it should be a wallpaper frame with the background "button.gif"
Then I should see "This is hella customized" in the framer preview Then I should see "This is hella customized" in the framer preview
#### Will test the template picker being ported to JS #### #changing the mood changes the presentation
# Then the default mood for the post should be "Wallpaper"
# And I should see the image "button.gif" background
When I select the mood "Day" When I select the mood "Day"
Then the post's mood should be "Day" Then the post's mood should be "Day"
And "button.gif" should be in the post's picture viewer And "button.gif" should be in the post's picture viewer
......
...@@ -16,9 +16,9 @@ describe("app.views.AspectsDropdown", function(){ ...@@ -16,9 +16,9 @@ describe("app.views.AspectsDropdown", function(){
this.view.render() this.view.render()
}) })
it("defaults to All Aspects Visibility", function(){ it("defaults to Public Visibility", function(){
expect(this.view.$("input.aspect_ids").val()).toBe("all_aspects") expect(this.view.$("input.aspect_ids").val()).toBe("public")
expect($.trim(this.view.$(".dropdown-toggle .text").text())).toBe("All Aspects") expect($.trim(this.view.$(".dropdown-toggle .text").text())).toBe("Public")
}) })
describe("selecting Public", function(){ describe("selecting Public", function(){
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter