issues.feature 6.02 KB
Newer Older
1
Feature: Project Issues
2
  Background:
3
    Given I sign in as a user
4 5
    And I own project "Shop"
    And project "Shop" have "Release 0.4" open issue
6
    And project "Shop" have "Tweet control" open issue
7
    And project "Shop" have "Release 0.3" closed issue
randx's avatar
randx committed
8
    And I visit project "Shop" issues page
9 10

  Scenario: I should see open issues
11 12
    Given I should see "Release 0.4" in issues
    And I should not see "Release 0.3" in issues
13

14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
  Scenario: I should see closed issues
    Given I click link "Closed"
    Then I should see "Release 0.3" in issues
    And I should not see "Release 0.4" in issues

  Scenario: I should see all issues
    Given I click link "All"
    Then I should see "Release 0.3" in issues
    And I should see "Release 0.4" in issues

  Scenario: I visit issue page
    Given I click link "Release 0.4"
    Then I should see issue "Release 0.4"

  Scenario: I submit new unassigned issue
    Given I click link "New Issue"
    And I submit new issue "500 error on profile"
    Then I should see issue "500 error on profile"

33 34 35 36 37 38 39
  Scenario: I submit new unassigned issue with labels
    Given project "Shop" has labels: "bug", "feature", "enhancement"
    And I click link "New Issue"
    And I submit new issue "500 error on profile" with label 'bug'
    Then I should see issue "500 error on profile"
    And I should see label 'bug' with issue

40 41 42 43
  @javascript
  Scenario: I comment issue
    Given I visit issue page "Release 0.4"
    And I leave a comment like "XML attached"
44
    Then I should see comment "XML attached"
randx's avatar
randx committed
45 46 47

  @javascript
  Scenario: I search issue
48
    Given I fill in issue search with "Re"
randx's avatar
randx committed
49 50
    Then I should see "Release 0.4" in issues
    And I should not see "Release 0.3" in issues
51
    And I should not see "Tweet control" in issues
randx's avatar
randx committed
52 53 54

  @javascript
  Scenario: I search issue that not exist
55
    Given I fill in issue search with "Bu"
randx's avatar
randx committed
56 57 58 59 60 61
    Then I should not see "Release 0.4" in issues
    And I should not see "Release 0.3" in issues

  @javascript
  Scenario: I search all issues
    Given I click link "All"
62
    And I fill in issue search with ".3"
randx's avatar
randx committed
63 64
    Then I should see "Release 0.3" in issues
    And I should not see "Release 0.4" in issues
65

66
  @javascript
67 68 69 70
  Scenario: Search issues when search string exactly matches issue description
    Given project 'Shop' has issue 'Bugfix1' with description: 'Description for issue1'
    And I fill in issue search with 'Description for issue1'
    Then I should see 'Bugfix1' in issues
71 72 73 74 75
    And I should not see "Release 0.4" in issues
    And I should not see "Release 0.3" in issues
    And I should not see "Tweet control" in issues

  @javascript
76 77 78 79 80 81
  Scenario: Search issues when search string partially matches issue description
    Given project 'Shop' has issue 'Bugfix1' with description: 'Description for issue1'
    And project 'Shop' has issue 'Feature1' with description: 'Feature submitted for issue1'
    And I fill in issue search with 'issue1'
    Then I should see 'Feature1' in issues
    Then I should see 'Bugfix1' in issues
82 83 84 85 86
    And I should not see "Release 0.4" in issues
    And I should not see "Release 0.3" in issues
    And I should not see "Tweet control" in issues

  @javascript
87 88 89 90
  Scenario: Search issues when search string matches no issue description
    Given project 'Shop' has issue 'Bugfix1' with description: 'Description for issue1'
    And I fill in issue search with 'Rock and roll'
    Then I should not see 'Bugfix1' in issues
91 92 93 94 95
    And I should not see "Release 0.4" in issues
    And I should not see "Release 0.3" in issues
    And I should not see "Tweet control" in issues


96 97 98 99 100 101 102 103 104 105 106
  # Markdown

  Scenario: Headers inside the description should have ids generated for them.
    Given I visit issue page "Release 0.4"
    Then Header "Description header" should have correct id and link

  @javascript
  Scenario: Headers inside comments should not have ids generated for them.
    Given I visit issue page "Release 0.4"
    And I leave a comment with a header containing "Comment with a header"
    Then The comment with the header should not have an ID
107

Marin Jankovski's avatar
Marin Jankovski committed
108 109 110 111 112 113
  @javascript
  Scenario: Blocks inside comments should not build relative links
    Given I visit issue page "Release 0.4"
    And I leave a comment with code block
    Then The code block should be unchanged

114 115 116 117 118 119 120 121
  Scenario: Issues on empty project
    Given empty project "Empty Project"
    When I visit empty project page
    And I see empty project details with ssh clone info
    When I visit empty project's issues page
    Given I click link "New Issue"
    And I submit new issue "500 error on profile"
    Then I should see issue "500 error on profile"
122 123 124 125 126 127 128

  Scenario: Clickable labels
    Given issue 'Release 0.4' has label 'bug'
    And I visit project "Shop" issues page
    When I click label 'bug'
    And I should see "Release 0.4" in issues
    And I should not see "Tweet control" in issues
129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161

  Scenario: Issue description should render task checkboxes
    Given project "Shop" has "Tasks-open" open issue with task markdown
    When I visit issue page "Tasks-open"
    Then I should see task checkboxes in the description

  @javascript
  Scenario: Issue notes should not render task checkboxes
    Given project "Shop" has "Tasks-open" open issue with task markdown
    When I visit issue page "Tasks-open"
    And I leave a comment with task markdown
    Then I should not see task checkboxes in the comment

  # Task status in issues list

  Scenario: Issues list should display task status
    Given project "Shop" has "Tasks-open" open issue with task markdown
    When I visit project "Shop" issues page
    Then I should see the task status for issue "Tasks-open"

  # Toggling task items

  @javascript
  Scenario: Task checkboxes should be enabled for an open issue
    Given project "Shop" has "Tasks-open" open issue with task markdown
    When I visit issue page "Tasks-open"
    Then Task checkboxes should be enabled

  @javascript
  Scenario: Task checkboxes should be disabled for a closed issue
    Given project "Shop" has "Tasks-closed" closed issue with task markdown
    When I visit issue page "Tasks-closed"
    Then Task checkboxes should be disabled