1call mtr.add_suppression("Plugin mysqlx reported: .Failed at SSL configuration: .SSL context is not usable without certificate and private key..");
2call mtr.add_suppression("Plugin mysqlx reported: .SSL_CTX_load_verify_locations failed.");
3#
4# Assert the user exist from the start
5#
6include/assert.inc [session_user should exist before X plugin install]
7#
8# Start X plugin and check all is OK
9#
10install plugin mysqlx soname "mysqlx.so";
11include/assert.inc [session_user should exist after X plugin install]
12#
13# Delete the user
14#
15DROP USER "mysql.session"@"localhost";
16call mtr.add_suppression("Plugin mysqlx reported: '1.1: Unsuccessful login attempt: Unable to switch context to user mysql.session'");
17call mtr.add_suppression("Plugin mysqlx reported: 'Unable to switch context to user mysql.session'");
18#
19# Recreate the user with an upgrade and see that X plugin works
20#
21Run mysql_upgrade
22mysql.columns_priv                                 OK
23mysql.db                                           OK
24mysql.engine_cost                                  OK
25mysql.event                                        OK
26mysql.func                                         OK
27mysql.general_log                                  OK
28mysql.gtid_executed                                OK
29mysql.help_category                                OK
30mysql.help_keyword                                 OK
31mysql.help_relation                                OK
32mysql.help_topic                                   OK
33mysql.innodb_index_stats                           OK
34mysql.innodb_table_stats                           OK
35mysql.ndb_binlog_index                             OK
36mysql.plugin                                       OK
37mysql.proc                                         OK
38mysql.procs_priv                                   OK
39mysql.proxies_priv                                 OK
40mysql.server_cost                                  OK
41mysql.servers                                      OK
42mysql.slave_master_info                            OK
43mysql.slave_relay_log_info                         OK
44mysql.slave_worker_info                            OK
45mysql.slow_log                                     OK
46mysql.tables_priv                                  OK
47mysql.time_zone                                    OK
48mysql.time_zone_leap_second                        OK
49mysql.time_zone_name                               OK
50mysql.time_zone_transition                         OK
51mysql.time_zone_transition_type                    OK
52mysql.user                                         OK
53mtr.global_suppressions                            OK
54mtr.test_suppressions                              OK
55sys.sys_config                                     OK
56include/assert.inc [session_user should exist after upgrade]
57RUN SELECT CURRENT_USER()
58
59CURRENT_USER()
60root@localhost
610 rows affected
62Mysqlx.Ok {
63  msg: "bye!"
64}
65#
66# Uninstall plugin and verify that user is still there
67#
68UNINSTALL PLUGIN mysqlx;
69include/assert.inc [session_user should exist after install]
70#
71# Cleaning
72#
73install plugin mysqlx soname "mysqlx.so";
74call mtr.add_suppression("Unable to use user mysql.session context *.*");
75call mtr.add_suppression("On plugin shutdown it was not possible to reset the server read mode settings. Try to reset it manually.");
76