aswi2021jmsd-gitlab4/tests/sample_test.py @ 02f63b07
1 | 7065d97a | Stanislav Král | def test_addition(): |
---|---|---|---|
2 | 9f021e9c | Stanislav Král | assert 1 + 1 == 2 |
3 | 7065d97a | Stanislav Král | |
4 | |||
5 | def test_index(client): |
||
6 | # fetch index page
|
||
7 | res = client.get('/') |
||
8 | |||
9 | # check HTTP status code
|
||
10 | assert res.status_code == 200 |
||
11 | |||
12 | # check response content
|
||
13 | assert res.get_data(as_text=True) == "Welcome to the X.509 management application homepage!" |