Commit 5a84f613 authored by Robert Czechowski's avatar Robert Czechowski
Browse files

Change tests to recognise new frontpage

parent d523e8ea
Pipeline #116 passed with stage
in 6 minutes and 20 seconds
...@@ -294,7 +294,7 @@ mod tests { ...@@ -294,7 +294,7 @@ mod tests {
check_status(&resp, reqwest::StatusCode::Ok); check_status(&resp, reqwest::StatusCode::Ok);
let mut content = String::new(); let mut content = String::new();
resp.read_to_string(&mut content).unwrap(); resp.read_to_string(&mut content).unwrap();
assert!(content.contains("<h1>Jugendwettbewerb Informatik</h1>")); assert!(content.contains("Jugendwettbewerb Informatik</h1>"));
assert!(!content.contains("Error")); assert!(!content.contains("Error"));
let mut resp = reqwest::get("http://localhost:8080/contest").unwrap(); let mut resp = reqwest::get("http://localhost:8080/contest").unwrap();
...@@ -346,7 +346,7 @@ mod tests { ...@@ -346,7 +346,7 @@ mod tests {
new_resp.read_to_string(&mut new_content).unwrap(); new_resp.read_to_string(&mut new_content).unwrap();
assert!(!content.contains("Error")); assert!(!content.contains("Error"));
assert!(new_content.contains("Eingeloggt als <em>testusr</em>")); 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 { } else {
panic!("More than one setCookie."); panic!("More than one setCookie.");
} }
...@@ -378,10 +378,10 @@ mod tests { ...@@ -378,10 +378,10 @@ mod tests {
let mut new_content = String::new(); let mut new_content = String::new();
new_resp.read_to_string(&mut new_content).unwrap(); new_resp.read_to_string(&mut new_content).unwrap();
assert!(new_content.contains("Benutzername:")); assert!(new_content.contains("Benutzername"));
assert!(new_content.contains("Passwort:")); assert!(new_content.contains("Passwort"));
assert!(new_content.contains("Gruppencode / Teilnahmecode:")); assert!(new_content.contains("Gruppencode / Teilnahmecode"));
assert!(new_content.contains("<h1>Jugendwettbewerb Informatik</h1>")); assert!(new_content.contains("Jugendwettbewerb Informatik</h1>"));
} else { } else {
panic!("More than one setCookie."); panic!("More than one setCookie.");
} }
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
</form> </form>
<form action="clogin" method="post"> <form action="clogin" method="post">
<div class="columns blogin"> <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="↪ &nbsp; Login"></div> <div class="column"><input class="button is-small is-success" type="submit" value="↪ &nbsp; Login"></div>
</div> </div>
</form> </form>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment