Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
f444c9cc
Commit
f444c9cc
authored
Mar 24, 2015
by
Valery Sizov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
deploy key events: tests
parent
7898922a
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
45 additions
and
0 deletions
+45
-0
features/project/audit_event.feature
features/project/audit_event.feature
+14
-0
features/steps/project/audit_event.rb
features/steps/project/audit_event.rb
+27
-0
features/steps/shared/paths.rb
features/steps/shared/paths.rb
+4
-0
No files found.
features/project/audit_event.feature
0 → 100644
View file @
f444c9cc
Feature
:
Audit Event
Background
:
Given
I sign in as a user
And
I own project
"Shop"
Scenario
:
I
add new deploy key
Given
I created new depoloy key
When
I visit audit event page
Then
I see deploy key event
When
I remove deploy key
And
I visit audit event page
Then
I see remove deploy key event
\ No newline at end of file
features/steps/project/audit_event.rb
0 → 100644
View file @
f444c9cc
class
Spinach::Features::AuditEvent
<
Spinach
::
FeatureSteps
include
SharedAuthentication
include
SharedProject
include
SharedPaths
step
'I created new depoloy key'
do
visit
new_namespace_project_deploy_key_path
(
@project
.
namespace
,
@project
)
fill_in
"deploy_key_title"
,
with:
"laptop"
fill_in
"deploy_key_key"
,
with:
"ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAzrEJUIR6Y03TCE9rIJ+GqTBvgb8t1jI9h5UBzCLuK4VawOmkLornPqLDrGbm6tcwM/wBrrLvVOqi2HwmkKEIecVO0a64A4rIYScVsXIniHRS6w5twyn1MD3sIbN+socBDcaldECQa2u1dI3tnNVcs8wi77fiRe7RSxePsJceGoheRQgC8AZ510UdIlO+9rjIHUdVN7LLyz512auAfYsgx1OfablkQ/XJcdEwDNgi9imI6nAXhmoKUm1IPLT2yKajTIC64AjLOnE0YyCh6+7RFMpiMyu1qiOCpdjYwTgBRiciNRZCH8xIedyCoAmiUgkUT40XYHwLuwiPJICpkAzp7Q== user@laptop"
click_button
"Create"
end
step
'I remove deploy key'
do
visit
namespace_project_deploy_keys_path
(
@project
.
namespace
,
@project
)
click_link
"Remove"
end
step
'I see remove deploy key event'
do
page
.
should
have_content
(
"Remove deploy key"
)
end
step
'I see deploy key event'
do
page
.
should
have_content
(
"Add deploy key"
)
end
end
features/steps/shared/paths.rb
View file @
f444c9cc
...
...
@@ -67,6 +67,10 @@ module SharedPaths
visit
edit_group_path
(
Group
.
find_by
(
name
:"Guest"
))
end
step
'I visit audit event page'
do
visit
namespace_project_audit_events_path
(
@project
.
namespace
,
@project
)
end
# ----------------------------------------
# Dashboard
# ----------------------------------------
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment