mirror of
https://github.com/internetee/registry.git
synced 2025-07-25 20:18:22 +02:00
added registrar credit changing functionality
This commit is contained in:
parent
4982aba97c
commit
2ff049707d
18 changed files with 271 additions and 2 deletions
20
test/system/admin_area/accounts_test.rb
Normal file
20
test/system/admin_area/accounts_test.rb
Normal file
|
@ -0,0 +1,20 @@
|
|||
require 'application_system_test_case'
|
||||
|
||||
class AdminAccountsSystemTest < ApplicationSystemTestCase
|
||||
setup do
|
||||
sign_in users(:admin)
|
||||
end
|
||||
|
||||
def test_download_accounts
|
||||
now = Time.zone.parse('2010-07-05 08:00')
|
||||
travel_to now
|
||||
|
||||
get admin_accounts_path(format: :csv)
|
||||
|
||||
assert_response :ok
|
||||
assert_equal 'text/csv; charset=utf-8', response.headers['Content-Type']
|
||||
assert_equal %(attachment; filename="accounts_#{Time.zone.now.to_formatted_s(:number)}.csv"; filename*=UTF-8''accounts_#{Time.zone.now.to_formatted_s(:number)}.csv),
|
||||
response.headers['Content-Disposition']
|
||||
assert_not_empty response.body
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue