diff test/controllers/pastes_controller_test.rb @ 484:84ca55a0568e

Fix pasting base64 gzip and fix tests
author nanaya <me@nanaya.pro>
date Sun, 28 Nov 2021 20:01:18 +0900
parents 1d113463d154
children
line wrap: on
line diff
--- a/test/controllers/pastes_controller_test.rb	Sun Nov 28 19:54:08 2021 +0900
+++ b/test/controllers/pastes_controller_test.rb	Sun Nov 28 20:01:18 2021 +0900
@@ -11,7 +11,7 @@
 
   test "creates paste from gzip" do
     assert_difference("Paste.count", 1) do
-      post :create, :params => { "paste" => { "paste_gzip" => ActiveSupport::Gzip.compress("here be paste") } }
+      post :create, :params => { "paste" => { "paste_gzip" => fixture_file_upload('hello_world.txt.gz') } }
     end
 
     assert_response :redirect