mirror of
https://github.com/dolthub/dolt.git
synced 2026-01-08 08:49:52 -06:00
In the migration to *SqlEngine in 0.34.4 to 0.34.5, the server config's respect for the default value for autocommit regressed. In 0.34.5 - 0.35.3, `autocommit` is always turned on by default for incoming connections, regardless of the setting in the config.yaml file or the flag `--no-auto-commit` being passed at the command line.
55 lines
1.0 KiB
Plaintext
55 lines
1.0 KiB
Plaintext
#!/usr/bin/expect
|
|
set timeout 10
|
|
|
|
set port [lindex $argv 0];
|
|
set database [lindex $argv 1];
|
|
|
|
spawn mysql --host 0.0.0.0 --port $port --user dolt
|
|
|
|
expect {
|
|
"mysql> " { send "show databases;\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect {
|
|
"*repo1*repo2*" { send "use repo1;\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect {
|
|
"*Database changed*" { send "show tables;\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect {
|
|
"*r1t_one*r1t_two*" { send "select count(*) from r1t_one;\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect {
|
|
"*3*" { send "use repo2;\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect {
|
|
"*Database changed*" { send "show tables;\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect {
|
|
"*r2t_three*" { send "select count(*) from r2t_three;\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect {
|
|
"*4*" { send "select @@autocommit;\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect {
|
|
"*0 |*" { send "exit\r"; }
|
|
timeout { exit 1; }
|
|
failed { exit 1; }
|
|
}
|
|
expect eof
|