aboutsummaryrefslogtreecommitdiff
path: root/internal/webui/root_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/webui/root_test.go')
-rw-r--r--internal/webui/root_test.go13
1 files changed, 3 insertions, 10 deletions
diff --git a/internal/webui/root_test.go b/internal/webui/root_test.go
index 7e4ec71..e96f1c8 100644
--- a/internal/webui/root_test.go
+++ b/internal/webui/root_test.go
@@ -24,15 +24,8 @@ func TestRootHandler(t *testing.T) {
require.Nil(t, err)
e := env{
dbEnv: dbEnv,
- conf: &config.Config{TrainStop: "test"},
+ conf: &config.Config{},
}
- departures1 := []model.Departure{
- model.Departure{
- Direction: "test direction",
- Arrival: "20210503T150405",
- },
- }
- e.navitia = &NavitiaMockClient{departures: departures1, err: nil}
// test GET requests
runHttpTest(t, &e, rootHandler, &httpTestCase{
name: "a simple get when not logged in should redirect to the login page",
@@ -46,7 +39,7 @@ func TestRootHandler(t *testing.T) {
},
})
runHttpTest(t, &e, rootHandler, &httpTestCase{
- name: "a simple get when logged in should display the departure times",
+ name: "a simple get when logged in should display the menu",
input: httpTestInput{
method: http.MethodGet,
path: "/",
@@ -54,7 +47,7 @@ func TestRootHandler(t *testing.T) {
},
expect: httpTestExpect{
code: http.StatusOK,
- bodyString: "Horaires des prochains trains",
+ bodyString: "Menu",
},
})
}