🧚 A practical web framework for Gleam

Update examples

+16 -16
+1 -1
examples/00-hello-world/test/app_test.gleam
··· 14 |> should.equal(200) 15 16 response.headers 17 - |> should.equal([#("content-type", "text/html")]) 18 19 response 20 |> testing.string_body
··· 14 |> should.equal(200) 15 16 response.headers 17 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 18 19 response 20 |> testing.string_body
+1 -1
examples/01-routing/test/app_test.gleam
··· 15 |> should.equal(200) 16 17 response.headers 18 - |> should.equal([#("content-type", "text/html")]) 19 20 response 21 |> testing.string_body
··· 15 |> should.equal(200) 16 17 response.headers 18 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 19 20 response 21 |> testing.string_body
+2 -2
examples/02-working-with-form-data/test/app_test.gleam
··· 15 |> should.equal(200) 16 17 response.headers 18 - |> should.equal([#("content-type", "text/html")]) 19 20 response 21 |> testing.string_body ··· 55 |> should.equal(200) 56 57 response.headers 58 - |> should.equal([#("content-type", "text/html")]) 59 60 response 61 |> testing.string_body
··· 15 |> should.equal(200) 16 17 response.headers 18 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 19 20 response 21 |> testing.string_body ··· 55 |> should.equal(200) 56 57 response.headers 58 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 59 60 response 61 |> testing.string_body
+2 -2
examples/03-working-with-json/test/app_test.gleam
··· 22 |> should.equal(415) 23 24 response.headers 25 - |> should.equal([#("accept", "application/json")]) 26 } 27 28 pub fn submit_missing_parameters_test() { ··· 49 |> should.equal(201) 50 51 response.headers 52 - |> should.equal([#("content-type", "application/json")]) 53 54 response 55 |> testing.string_body
··· 22 |> should.equal(415) 23 24 response.headers 25 + |> should.equal([#("accept", "application/json; charset=utf-8")]) 26 } 27 28 pub fn submit_missing_parameters_test() { ··· 49 |> should.equal(201) 50 51 response.headers 52 + |> should.equal([#("content-type", "application/json; charset=utf-8")]) 53 54 response 55 |> testing.string_body
+1 -1
examples/05-using-a-database/test/app_test.gleam
··· 40 response.status 41 |> should.equal(200) 42 response.headers 43 - |> should.equal([#("content-type", "application/json")]) 44 45 // Initially there are no people in the database 46 response
··· 40 response.status 41 |> should.equal(200) 42 response.headers 43 + |> should.equal([#("content-type", "application/json; charset=utf-8")]) 44 45 // Initially there are no people in the database 46 response
+1 -1
examples/06-serving-static-assets/test/app_test.gleam
··· 26 |> should.equal(200) 27 28 response.headers 29 - |> should.equal([#("content-type", "text/html")]) 30 } 31 32 pub fn get_stylesheet_test() {
··· 26 |> should.equal(200) 27 28 response.headers 29 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 30 } 31 32 pub fn get_stylesheet_test() {
+7 -7
examples/09-configuring-default-responses/test/app_test.gleam
··· 15 |> should.equal(200) 16 17 response.headers 18 - |> should.equal([#("content-type", "text/html")]) 19 20 let assert True = 21 response ··· 31 |> should.equal(500) 32 33 response.headers 34 - |> should.equal([#("content-type", "text/html")]) 35 36 let assert True = 37 response ··· 46 |> should.equal(422) 47 48 response.headers 49 - |> should.equal([#("content-type", "text/html")]) 50 51 let assert True = 52 response ··· 61 |> should.equal(400) 62 63 response.headers 64 - |> should.equal([#("content-type", "text/html")]) 65 66 let assert True = 67 response ··· 76 |> should.equal(405) 77 78 response.headers 79 - |> should.equal([#("allow", ""), #("content-type", "text/html")]) 80 81 let assert True = 82 response ··· 91 |> should.equal(404) 92 93 response.headers 94 - |> should.equal([#("content-type", "text/html")]) 95 96 let assert True = 97 response ··· 106 |> should.equal(413) 107 108 response.headers 109 - |> should.equal([#("content-type", "text/html")]) 110 111 let assert True = 112 response
··· 15 |> should.equal(200) 16 17 response.headers 18 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 19 20 let assert True = 21 response ··· 31 |> should.equal(500) 32 33 response.headers 34 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 35 36 let assert True = 37 response ··· 46 |> should.equal(422) 47 48 response.headers 49 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 50 51 let assert True = 52 response ··· 61 |> should.equal(400) 62 63 response.headers 64 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 65 66 let assert True = 67 response ··· 76 |> should.equal(405) 77 78 response.headers 79 + |> should.equal([#("allow", ""), #("content-type", "text/html; charset=utf-8")]) 80 81 let assert True = 82 response ··· 91 |> should.equal(404) 92 93 response.headers 94 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 95 96 let assert True = 97 response ··· 106 |> should.equal(413) 107 108 response.headers 109 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 110 111 let assert True = 112 response
+1 -1
examples/10-working-with-files/test/app_test.gleam
··· 15 |> should.equal(200) 16 17 response.headers 18 - |> should.equal([#("content-type", "text/html")]) 19 20 response 21 |> testing.string_body
··· 15 |> should.equal(200) 16 17 response.headers 18 + |> should.equal([#("content-type", "text/html; charset=utf-8")]) 19 20 response 21 |> testing.string_body