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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
6113d806
Commit
6113d806
authored
Sep 13, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'remote_url_in_project_blank_slate' of /home/git/repositories/gitlab/gitlabhq
parents
5ff79f94
c606df8f
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
38 additions
and
2 deletions
+38
-2
app/assets/javascripts/project.js.coffee
app/assets/javascripts/project.js.coffee
+1
-0
app/views/projects/empty.html.haml
app/views/projects/empty.html.haml
+4
-2
features/project/create_project.feature
features/project/create_project.feature
+11
-0
features/steps/project/create_project.rb
features/steps/project/create_project.rb
+22
-0
No files found.
app/assets/javascripts/project.js.coffee
View file @
6113d806
...
...
@@ -35,6 +35,7 @@ $ ->
$
(
'a, button'
,
scope
).
removeClass
'active'
$
(
@
).
addClass
'active'
$
(
'#project_clone'
,
scope
).
val
$
(
@
).
data
'clone'
$
(
".clone"
).
text
(
""
).
append
'git remote add origin '
+
$
(
@
).
data
'clone'
# Ref switcher
$
(
'.project-refs-select'
).
on
'change'
,
->
...
...
app/views/projects/empty.html.haml
View file @
6113d806
...
...
@@ -29,7 +29,8 @@
touch README
git add README
git commit -m 'first commit'
git remote add origin
#{
@project
.
url_to_repo
}
%span
.clone
=
"git remote add origin
#{
@project
.
url_to_repo
}
"
:preserve
git push -u origin master
%fieldset
...
...
@@ -37,7 +38,8 @@
%pre
.dark
:preserve
cd existing_git_repo
git remote add origin
#{
@project
.
url_to_repo
}
%span
.clone
=
"git remote add origin
#{
@project
.
url_to_repo
}
"
:preserve
git push -u origin master
-
if
can?
current_user
,
:remove_project
,
@project
...
...
features/project/create_project.feature
View file @
6113d806
...
...
@@ -9,3 +9,14 @@ Feature: Create Project
And
fill project form with valid data
Then
I should see project page
And
I should see empty project instuctions
@javascript
Scenario
:
Empty project instructions
Given
I sign in as a user
When
I visit new project page
And
fill project form with valid data
Then
I see empty project instuctions
And
I click on HTTP
Then
Remote url should update to http link
And
If I click on SSH
Then
Remote url should update to ssh link
\ No newline at end of file
features/steps/project/create_project.rb
View file @
6113d806
...
...
@@ -17,4 +17,26 @@ class CreateProject < Spinach::FeatureSteps
page
.
should
have_content
"git remote"
page
.
should
have_content
Project
.
last
.
url_to_repo
end
Then
'I see empty project instuctions'
do
page
.
should
have_content
"git init"
page
.
should
have_content
"git remote"
page
.
should
have_content
Project
.
last
.
url_to_repo
end
And
'I click on HTTP'
do
click_button
'HTTP'
end
Then
'Remote url should update to http link'
do
page
.
should
have_content
"git remote add origin
#{
Project
.
last
.
http_url_to_repo
}
"
end
And
'If I click on SSH'
do
click_button
'SSH'
end
Then
'Remote url should update to ssh link'
do
page
.
should
have_content
"git remote add origin
#{
Project
.
last
.
url_to_repo
}
"
end
end
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