diff --git a/app/config/kemal.cr b/app/config/kemal.cr index ff464c7..8b2cf3c 100644 --- a/app/config/kemal.cr +++ b/app/config/kemal.cr @@ -3,5 +3,3 @@ require "kemal" Kemal.config.env = ENV["ENV"]? || "development" Kemal.config.port = ENV["PORT"]?.try(&.to_i) || 4000 Kemal.config.host_binding = ENV["HOST"]? || "0.0.0.0" - -Kemal.config.logging = true diff --git a/spec/integration/link_spec.cr b/spec/integration/link_spec.cr index e78ee74..878eb6f 100644 --- a/spec/integration/link_spec.cr +++ b/spec/integration/link_spec.cr @@ -78,10 +78,11 @@ describe App::Controllers::Link do serialized_link = App::Serializers::Link.new(test_link) get(serialized_link.refer, headers: HTTP::Headers{"X-Api-Key" => test_user.api_key.to_s}) - - updated_test_link = get_test_link(test_link.id) + Fiber.yield response.headers["Location"].should eq(link) + + updated_test_link = get_test_link(test_link.id) updated_test_link.click_counter.should eq(1) end diff --git a/spec/spec_helper.cr b/spec/spec_helper.cr index ea7dfd5..d06b1e1 100644 --- a/spec/spec_helper.cr +++ b/spec/spec_helper.cr @@ -8,6 +8,8 @@ require "../url-shortener" Spec.before_suite do Micrate::DB.connection_url = ENV["DATABASE_URL"] Micrate::Cli.run_up + + Kemal.config.logging = false end def create_test_user