mirror of
https://github.com/internetee/registry.git
synced 2025-06-07 13:15:40 +02:00
Clean up settings after tests
This commit is contained in:
parent
840f1db5c9
commit
7fcab05e51
15 changed files with 74 additions and 22 deletions
|
@ -1,6 +1,16 @@
|
|||
require 'test_helper'
|
||||
|
||||
class RegistryTest < ActiveSupport::TestCase
|
||||
setup do
|
||||
@original_registry_vat_rate = Setting.registry_vat_prc
|
||||
@original_registry_country_code = Setting.registry_country_code
|
||||
end
|
||||
|
||||
teardown do
|
||||
Setting.registry_vat_prc = @original_registry_vat_rate
|
||||
Setting.registry_country_code = @original_registry_country_code
|
||||
end
|
||||
|
||||
def test_returns_current_registry
|
||||
Setting.registry_vat_prc = 0.2
|
||||
Setting.registry_country_code = 'US'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue