Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
bwinf
medal
Commits
5a84f613
Commit
5a84f613
authored
Jun 06, 2019
by
Robert Czechowski
Browse files
Change tests to recognise new frontpage
parent
d523e8ea
Pipeline
#116
passed with stage
in 6 minutes and 20 seconds
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
src/main.rs
View file @
5a84f613
...
...
@@ -294,7 +294,7 @@ mod tests {
check_status
(
&
resp
,
reqwest
::
StatusCode
::
Ok
);
let
mut
content
=
String
::
new
();
resp
.read_to_string
(
&
mut
content
)
.unwrap
();
assert
!
(
content
.contains
(
"
<h1>
Jugendwettbewerb Informatik</h1>"
));
assert
!
(
content
.contains
(
"Jugendwettbewerb Informatik</h1>"
));
assert
!
(
!
content
.contains
(
"Error"
));
let
mut
resp
=
reqwest
::
get
(
"http://localhost:8080/contest"
)
.unwrap
();
...
...
@@ -346,7 +346,7 @@ mod tests {
new_resp
.read_to_string
(
&
mut
new_content
)
.unwrap
();
assert
!
(
!
content
.contains
(
"Error"
));
assert
!
(
new_content
.contains
(
"Eingeloggt als <em>testusr</em>"
));
assert
!
(
new_content
.contains
(
"
<h1>
Jugendwettbewerb Informatik</h1>"
));
assert
!
(
new_content
.contains
(
"Jugendwettbewerb Informatik</h1>"
));
}
else
{
panic!
(
"More than one setCookie."
);
}
...
...
@@ -378,10 +378,10 @@ mod tests {
let
mut
new_content
=
String
::
new
();
new_resp
.read_to_string
(
&
mut
new_content
)
.unwrap
();
assert
!
(
new_content
.contains
(
"Benutzername
:
"
));
assert
!
(
new_content
.contains
(
"Passwort
:
"
));
assert
!
(
new_content
.contains
(
"Gruppencode / Teilnahmecode
:
"
));
assert
!
(
new_content
.contains
(
"
<h1>
Jugendwettbewerb Informatik</h1>"
));
assert
!
(
new_content
.contains
(
"Benutzername"
));
assert
!
(
new_content
.contains
(
"Passwort"
));
assert
!
(
new_content
.contains
(
"Gruppencode / Teilnahmecode"
));
assert
!
(
new_content
.contains
(
"Jugendwettbewerb Informatik</h1>"
));
}
else
{
panic!
(
"More than one setCookie."
);
}
...
...
templates/index.hbs
View file @
5a84f613
...
...
@@ -47,7 +47,7 @@
</form>
<form
action=
"clogin"
method=
"post"
>
<div
class=
"columns blogin"
>
<div
class=
"column is-four-fifths"
><input
class=
"input is-small"
type=
"text"
name=
"code"
placeholder=
"Gruppencode"
></div>
<div
class=
"column is-four-fifths"
><input
class=
"input is-small"
type=
"text"
name=
"code"
placeholder=
"Gruppencode
/ Teilnahmecode
"
></div>
<div
class=
"column"
><input
class=
"button is-small is-success"
type=
"submit"
value=
"↪ Login"
></div>
</div>
</form>
...
...
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