Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
caddy
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
nexedi
caddy
Commits
d44ab3db
Commit
d44ab3db
authored
Sep 04, 2015
by
Matt Holt
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #229 from LK4D4/fix_format
Fix formatting directives in tests
parents
94becb89
b199825c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
config/setup/markdown_test.go
config/setup/markdown_test.go
+1
-1
middleware/recorder_test.go
middleware/recorder_test.go
+2
-2
No files found.
config/setup/markdown_test.go
View file @
d44ab3db
...
@@ -111,7 +111,7 @@ func TestMarkdownStaticGen(t *testing.T) {
...
@@ -111,7 +111,7 @@ func TestMarkdownStaticGen(t *testing.T) {
fp
:=
filepath
.
Join
(
c
.
Root
,
markdown
.
DefaultStaticDir
)
fp
:=
filepath
.
Join
(
c
.
Root
,
markdown
.
DefaultStaticDir
)
if
err
=
os
.
RemoveAll
(
fp
);
err
!=
nil
{
if
err
=
os
.
RemoveAll
(
fp
);
err
!=
nil
{
t
.
Errorf
(
"Error while removing the generated static files: "
,
err
)
t
.
Errorf
(
"Error while removing the generated static files:
%v
"
,
err
)
}
}
}
}
...
...
middleware/recorder_test.go
View file @
d44ab3db
...
@@ -13,7 +13,7 @@ func TestNewResponseRecorder(t *testing.T) {
...
@@ -13,7 +13,7 @@ func TestNewResponseRecorder(t *testing.T) {
t
.
Fatalf
(
"Expected Response writer in the Recording to be same as the one sent
\n
"
)
t
.
Fatalf
(
"Expected Response writer in the Recording to be same as the one sent
\n
"
)
}
}
if
recordRequest
.
status
!=
http
.
StatusOK
{
if
recordRequest
.
status
!=
http
.
StatusOK
{
t
.
Fatalf
(
"Expected recorded status to be http.StatusOK (%d) , but found %d
\n
"
,
recordRequest
.
status
)
t
.
Fatalf
(
"Expected recorded status to be http.StatusOK (%d) , but found %d
\n
"
,
http
.
StatusOK
,
recordRequest
.
status
)
}
}
}
}
func
TestWriteHeader
(
t
*
testing
.
T
)
{
func
TestWriteHeader
(
t
*
testing
.
T
)
{
...
@@ -35,6 +35,6 @@ func TestWrite(t *testing.T) {
...
@@ -35,6 +35,6 @@ func TestWrite(t *testing.T) {
t
.
Fatalf
(
"Expected the bytes written counter to be %d, but instead found %d
\n
"
,
len
(
buf
),
recordRequest
.
size
)
t
.
Fatalf
(
"Expected the bytes written counter to be %d, but instead found %d
\n
"
,
len
(
buf
),
recordRequest
.
size
)
}
}
if
w
.
Body
.
String
()
!=
responseTestString
{
if
w
.
Body
.
String
()
!=
responseTestString
{
t
.
Fatalf
(
"Expected Response Body to be %s , but found %s
\n
"
,
w
.
Body
.
String
())
t
.
Fatalf
(
"Expected Response Body to be %s , but found %s
\n
"
,
responseTestString
,
w
.
Body
.
String
())
}
}
}
}
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