| 1 |
# Test if registering a system variable twice will be rejected. |
| 2 |
|
| 3 |
--source ../include/have_component_test_sys_var_service.inc |
| 4 |
|
| 5 |
call mtr.add_suppression("duplicate variable name"); |
| 6 |
call mtr.add_suppression("variable name.*not found"); |
| 7 |
--echo # Simple load test |
| 8 |
INSTALL COMPONENT "file://component_test_sys_var_service"; |
| 9 |
INSTALL COMPONENT "file://component_test_sys_var_service_same"; |
| 10 |
|
| 11 |
--echo # Testing enum type variable |
| 12 |
SELECT @@test_component.enum_sys_var; |
| 13 |
SET GLOBAL test_component.enum_sys_var="LOW"; |
| 14 |
SELECT @@test_component.enum_sys_var; |
| 15 |
|
| 16 |
--echo # Testing string type variable |
| 17 |
SELECT @@test_component.str_sys_var; |
| 18 |
SET GLOBAL test_component.str_sys_var="dictionary.txt"; |
| 19 |
SELECT @@test_component.str_sys_var; |
| 20 |
SET GLOBAL test_component.str_sys_var=default; |
| 21 |
SELECT @@test_component.str_sys_var; |
| 22 |
|
| 23 |
--echo # Testing unsigned integer type variable |
| 24 |
SELECT @@test_component.uint_sys_var; |
| 25 |
SET GLOBAL test_component.uint_sys_var=12345678; |
| 26 |
SELECT @@test_component.uint_sys_var; |
| 27 |
SET GLOBAL test_component.uint_sys_var=default; |
| 28 |
SELECT @@test_component.uint_sys_var; |
| 29 |
|
| 30 |
--echo # Testing long type variable |
| 31 |
SELECT @@test_component.long_sys_var; |
| 32 |
SET GLOBAL test_component.long_sys_var=1234567890; |
| 33 |
SELECT @@test_component.long_sys_var; |
| 34 |
SET GLOBAL test_component.long_sys_var=default; |
| 35 |
SELECT @@test_component.long_sys_var; |
| 36 |
|
| 37 |
--echo # Testing unsigned long type variable |
| 38 |
SELECT @@test_component.ulong_sys_var; |
| 39 |
SET GLOBAL test_component.ulong_sys_var=1234567890; |
| 40 |
SELECT @@test_component.ulong_sys_var; |
| 41 |
SET GLOBAL test_component.ulong_sys_var=default; |
| 42 |
SELECT @@test_component.ulong_sys_var; |
| 43 |
|
| 44 |
--echo # Testing long long type variable |
| 45 |
SELECT @@test_component.longlong_sys_var; |
| 46 |
SET GLOBAL test_component.longlong_sys_var=1234567890; |
| 47 |
SELECT @@test_component.longlong_sys_var; |
| 48 |
SET GLOBAL test_component.longlong_sys_var=default; |
| 49 |
SELECT @@test_component.longlong_sys_var; |
| 50 |
|
| 51 |
UNINSTALL COMPONENT "file://component_test_sys_var_service"; |
| 52 |
UNINSTALL COMPONENT "file://component_test_sys_var_service_same"; |
| 53 |
|
| 54 |
# Write the test results of the test components into the |
| 55 |
# result file of this test |
| 56 |
--echo ########## test_component_sys_var_service.log: |
| 57 |
let $MYSQLD_DATADIR= `select @@datadir`; |
| 58 |
cat_file $MYSQLD_DATADIR/test_component_sys_var_service.log; |
| 59 |
remove_file $MYSQLD_DATADIR/test_component_sys_var_service.log; |
| 60 |
|
| 61 |
--echo ########## test_component_sys_var_service_same.log: |
| 62 |
let $MYSQLD_DATADIR= `select @@datadir`; |
| 63 |
cat_file $MYSQLD_DATADIR/test_component_sys_var_service_same.log; |
| 64 |
remove_file $MYSQLD_DATADIR/test_component_sys_var_service_same.log; |