Skip to content

Commit 154e9a3

Browse files
committed
fix test
1 parent 166cf60 commit 154e9a3

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

test/lti_example_tool_test.gleam

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import gleam/bit_array
12
import gleam/http/response
23
import gleam/list
34
import gleam/result
@@ -64,11 +65,14 @@ pub fn get_home_page_test() {
6465
let response = router.handle_request(request, ctx)
6566

6667
response.status
67-
|> should.equal(303)
68+
|> should.equal(200)
6869

69-
response.headers
70-
|> list.contains(#("location", "/registrations"))
71-
|> should.be_true
70+
response
71+
|> testing.bit_array_body()
72+
|> bit_array.to_string()
73+
|> result.map(string.contains(_, "LTI Example Tool"))
74+
|> result.unwrap(False)
75+
|> should.be_true()
7276

7377
response.headers
7478
|> list.contains(#("made-with", "Gleam"))

0 commit comments

Comments
 (0)