Skip to content

Commit a02d875

Browse files
committed
Add a test
1 parent 1bea71c commit a02d875

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

test/controllers/admin_controller_test.rb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,4 +157,12 @@ class AdminControllerTest < ActionController::TestCase
157157
assert_not_nil flash[:success]
158158
end
159159
end
160+
161+
test 'audit log should work with filter params' do
162+
sign_in users(:admin)
163+
get :audit_log, params: { log_type: 'admin_audit', event_type: 'setting_update', from: '2025-04-13',
164+
to: '2025-04-13' }
165+
assert_response(:success)
166+
assert_not_nil assigns(:logs)
167+
end
160168
end

0 commit comments

Comments
 (0)