Skip to content
Extraits de code Groupes Projets
Valider fd05d30f rédigé par carolina's avatar carolina Validation de mokus
Parcourir les fichiers

Add tests for photo link in profile side bar

parent 8df8855a
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
@javascript
Feature: show photos
Background:
Given following users exist:
| username | email |
| Bob Jones | bob@bob.bob |
| Alice Smith | alice@alice.alice |
| Robert Grimm | robert@grimm.grimm |
And I sign in as "robert@grimm.grimm"
Given I expand the publisher
And I have turned off jQuery effects
And I attach the file "spec/fixtures/button.png" to hidden "file" within "#file-upload"
And I press "Share"
Scenario: see my own photos
And I am on "robert@grimm.grimm"'s page
When I follow "View all"
Then I should be on person_photos page
Scenario: I cannot see photos of people who don't share with me
When I sign in as "alice@alice.alice"
And I am on "robert@grimm.grimm"'s page
Then I should not see "photos" within "div#profile"
module NavigationHelpers module NavigationHelpers
def path_to(page_name) def path_to(page_name)
case page_name case page_name
when /^person_photos page$/
person_photos_path(@me.person)
when /^the home(?: )?page$/ when /^the home(?: )?page$/
stream_path stream_path
when /^step (\d)$/ when /^step (\d)$/
......
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