Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
heptapod
heptapod
Commits
1cab5576112a
Commit
ca504a77
authored
Feb 14, 2015
by
Hannes Rosenögger
Committed by
Douwe Maan
Feb 17, 2015
Browse files
Fix tests
parent
c5f59215fc32
Changes
1
Hide whitespace changes
Inline
Side-by-side
spec/services/projects/file_service_spec.rb
View file @
1cab5576
...
...
@@ -20,7 +20,7 @@
it
{
expect
(
@link_to_file
).
to
have_key
(
'is_image'
)
}
it
{
expect
(
@link_to_file
).
to
have_value
(
'banana_sample'
)
}
it
{
expect
(
@link_to_file
[
'is_image'
]).
to
equal
(
true
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
"
http://test.example/upload
s/
#{
@project
.
path_with_namespace
}
"
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
"
/file
s/
#{
@project
.
path_with_namespace
}
"
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
'banana_sample.gif'
)
}
end
...
...
@@ -38,7 +38,7 @@
it
{
expect
(
@link_to_file
).
to
have_value
(
'dk'
)
}
it
{
expect
(
@link_to_file
).
to
have_key
(
'is_image'
)
}
it
{
expect
(
@link_to_file
[
'is_image'
]).
to
equal
(
true
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
"
http://test.example/upload
s/
#{
@project
.
path_with_namespace
}
"
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
"
/file
s/
#{
@project
.
path_with_namespace
}
"
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
'dk.png'
)
}
end
...
...
@@ -53,7 +53,7 @@
it
{
expect
(
@link_to_file
).
to
have_key
(
'is_image'
)
}
it
{
expect
(
@link_to_file
).
to
have_value
(
'rails_sample'
)
}
it
{
expect
(
@link_to_file
[
'is_image'
]).
to
equal
(
true
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
"
http://test.example/upload
s/
#{
@project
.
path_with_namespace
}
"
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
"
/file
s/
#{
@project
.
path_with_namespace
}
"
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
'rails_sample.jpg'
)
}
end
...
...
@@ -70,7 +70,7 @@
it
{
expect
(
@link_to_file
).
to
have_key
(
'is_image'
)
}
it
{
expect
(
@link_to_file
).
to
have_value
(
'doc_sample.txt'
)
}
it
{
expect
(
@link_to_file
[
'is_image'
]).
to
equal
(
false
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
"
http://test.example/upload
s/
#{
@project
.
path_with_namespace
}
"
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
"
/file
s/
#{
@project
.
path_with_namespace
}
"
)
}
it
{
expect
(
@link_to_file
[
'url'
]).
to
match
(
'doc_sample.txt'
)
}
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