Commit Graph

17 Commits

Author SHA1 Message Date
Arpit Jalan e9a81064e7 Revert "FIX: fixnum type site setting can't be more than 20000"
This reverts commit 636cc66e1f.
2015-07-13 22:53:44 +05:30
Arpit Jalan 636cc66e1f FIX: fixnum type site setting can't be more than 20000 2015-07-13 18:58:45 +05:30
Arthur Neves e0ea68b9ca
Fix tests on site_setting for new rspec 2015-04-25 11:33:26 -04:00
Arthur Neves b8cbe51026
Convert specs to RSpec 2.99.2 syntax with Transpec
This conversion is done by Transpec 3.1.0 with the following command:
    transpec

* 424 conversions
    from: obj.should
      to: expect(obj).to

* 325 conversions
    from: == expected
      to: eq(expected)

* 38 conversions
    from: obj.should_not
      to: expect(obj).not_to

* 15 conversions
    from: =~ /pattern/
      to: match(/pattern/)

* 9 conversions
    from: it { should ... }
      to: it { is_expected.to ... }

* 5 conversions
    from: lambda { }.should_not
      to: expect { }.not_to

* 4 conversions
    from: lambda { }.should
      to: expect { }.to

* 2 conversions
    from: -> { }.should
      to: expect { }.to

* 2 conversions
    from: -> { }.should_not
      to: expect { }.not_to

* 1 conversion
    from: === expected
      to: be === expected

* 1 conversion
    from: =~ [1, 2]
      to: match_array([1, 2])

For more details: https://github.com/yujinakayama/transpec#supported-conversions
2015-04-25 11:18:35 -04:00
Arpit Jalan 2ee033caa5 FIX: validate integer site setting 2015-04-23 18:15:14 +05:30
Sam 0742f340f9 FEATURE: allow for a localized error when a regex fails in site settings
FEATURE: apply string validation to list site settings (so we get regex)
2015-02-27 11:45:56 +11:00
Sam a4b96adfc5 eliminate cross talk in site setting test 2015-02-04 16:57:16 +11:00
Robin Ward aacf2e6f20 Can add `shadowed_by_global` to a site setting to override
If a site setting has `shadowed_by_global: true` then, if
a `GlobalSetting` exists with the same name then that value
will be used instead.  Additionally, the setting will be hidden.

This is useful in a multisite environment for private settings
such as API keys. You want to set it globally, yet not display
the key to customers.
2015-02-03 16:49:22 -05:00
Arpit Jalan 3b2a5f6894 FIX: filter whitelist domain name 2014-07-24 22:02:10 +05:30
Neil Lalonde ba65aa3f6c Add a way to validate min and max value of an integer site setting 2014-06-12 18:04:37 -04:00
Neil Lalonde c61462662b Add ability to run validation on site settings. notification_email and other email address settings are now validated. 2014-06-09 16:59:20 -04:00
Neil Lalonde f97d434174 Fix the spec for enum site settings 2014-06-09 15:28:03 -04:00
Sam 8fc2549873 Stop using global vars where not needed
Simplify local process site setting provider
Stop setting up methods over and over
Centralize cache clearing
2014-03-31 12:34:13 +11:00
Neil Lalonde 74f1c553e3 FIX: 1868 Security: Dangerous Send 2014-01-27 13:05:51 -05:00
Neil Lalonde fc180ccd71 Site settings: move category into the opts hash so that it's compatibale with existing plugins 2013-11-15 14:32:33 -05:00
Neil Lalonde 1e37abc310 Add site setting category support 2013-11-14 16:02:13 -05:00
Neil Lalonde 791f5ac94e Load site settings from config/site_settings.yml 2013-11-14 16:02:13 -05:00