[Rt-commit] rt branch, 4.6/configindatabase-themed, repushed
Blaine Motsinger
blaine at bestpractical.com
Fri Nov 22 16:42:33 EST 2019
The branch 4.6/configindatabase-themed was deleted and repushed:
was e2d543a33587bfb049dbbd5462b3e498d5e47d22
now e52543afaf3ba19df0c122bdb839f6011c1bc250
1: b28dc30467 = 1: b28dc30467 Allow specifying size for Integer and String widgets
2: 94744da2c6 = 2: 94744da2c6 Allow String widget to have a value of "0"
3: 59334314c9 = 3: 59334314c9 Add RadioStyle option to Boolean widget
4: 534bba3102 = 4: 534bba3102 Make booleans with RadioStyle use true/false logic
5: baf23200cd = 5: baf23200cd DatabaseSetting schema updates
6: a888aa6cb0 = 6: a888aa6cb0 Add ORM classes for DatabaseSettings
7: 05db0b9b37 = 7: 05db0b9b37 Port database config loading and refreshing from extension
8: 7648dd10f1 = 8: 7648dd10f1 Add Code and MultilineString widgets
9: 21f6abfb8c = 9: 21f6abfb8c Port EditConfig page from extension
10: 165422a396 = 10: 165422a396 Annotate Immutable options
11: f2f0b772d7 = 11: f2f0b772d7 Add widget metadata for config options
12: 5803325e5f = 12: 5803325e5f Hide deprecated options
13: b878fb9786 = 13: b878fb9786 List Database as source of configuration on Sys Config page
14: 02b6a1a9fb = 14: 02b6a1a9fb Render config with EditLink as readonly
15: 94cbaf03d2 = 15: 94cbaf03d2 Switch from Storable::dclone to Clone::clone to handle code/regex
16: c0d5683bfb = 16: c0d5683bfb Migrate MultilineString to new themes
17: 9fcde4980a = 17: 9fcde4980a Add LabelLink support for form widgets
18: 1eee9b8f55 = 18: 1eee9b8f55 Vertically align boolean label/value
19: fb5f04660a = 19: fb5f04660a Add tabs to the Configuration in DB feature
20: 21ff2fa0c2 = 20: 21ff2fa0c2 Add missing config options to %META
21: 5523105073 = 21: 5523105073 Rename DatabaseSetting to Configuration
22: d80765bfaf = 22: d80765bfaf Validate Content of Configurations
23: 1ada6c8511 = 23: 1ada6c8511 Use Data::Dumper instead in Configuration to support regex
24: 165ca1445f = 24: 165ca1445f Note RT::Extension::ConfigInDatabase is cored and the main backend change
25: e2d543a335 ! 25: e52543afaf Add test for /Admin/Tools/EditConfig.html
@@ -13,6 +13,7 @@
+use strict;
+use warnings;
+
++use Test::Deep;
+use Data::Dumper ();
+
+use RT::Test tests => undef;
@@ -54,37 +55,40 @@
+sub run_test {
+ my %args = @_;
+
-+ $args{new_value} = stringify( $args{new_value} ) if ref $args{new_value};
-+
+ note $args{name} if $ENV{TEST_VERBOSE};
+
+ $m->submit_form_ok(
+ {
+ form_id => $args{form_id},
+ fields => {
-+ $args{setting} => $args{new_value}
++ $args{setting} => stringify( $args{new_value} ),
+ },
+ },
+ 'form was submitted successfully'
+ );
+
++ # RT::Config in the test is not running in the same process as the one in the test server.
++ # ensure the config object in the test is up to date with the changes.
+ RT->Config->LoadConfigFromDatabase();
+
+ $m->content_like( qr/$args{setting} changed from/, 'UI indicated the value was changed' );
+
++ # RT::Configuration->Content returns the value as string.
++ # in the test below we need to also ensure the new value is string.
+ my $rt_configuration = RT::Configuration->new( RT->SystemUser );
+ $rt_configuration->Load( $args{setting} );
+ my $rt_configuration_value = $rt_configuration->Content;
+
+ my $rt_config_value = RT->Config->Get( $args{setting} );
-+ $rt_config_value = stringify( $rt_config_value ) if ref $rt_config_value;
+
-+ is( $rt_configuration_value, $args{new_value}, 'value from RT::Configuration->Load matches new value' );
-+ is( $rt_config_value, $args{new_value}, 'value from RT->Config->Get matches new value' );
++ cmp_deeply( $rt_configuration_value, stringify($args{new_value}), 'value from RT::Configuration->Load matches new value' );
++ cmp_deeply( $rt_config_value, $args{new_value}, 'value from RT->Config->Get matches new value' );
+}
+
+sub stringify {
+ my $value = shift;
++
++ return $value unless ref $value;
+
+ local $Data::Dumper::Terse = 1;
+ local $Data::Dumper::Indent = 2;
More information about the rt-commit
mailing list