diff options
author | Jeremy Harris <jgh146exb@wizmail.org> | 2018-01-18 11:58:10 +0000 |
---|---|---|
committer | Jeremy Harris <jgh146exb@wizmail.org> | 2018-01-19 09:37:34 +0000 |
commit | f1a496844eddb421ba2a36e551dd308b8a565162 (patch) | |
tree | c4ba0bae3cd4c2370b442be9f9e5422cf0abd352 | |
parent | 50936073b7f81a4ca991809d02c77f6fd7813c80 (diff) |
Testsuite: munge output for platform variances in postgres server binary location
-rwxr-xr-x | test/runtest | 3 | ||||
-rw-r--r-- | test/scripts/2610-MySQL/2610 | 6 | ||||
-rw-r--r-- | test/src/client.c | 4 | ||||
-rw-r--r-- | test/stdout/2620 | 2 |
4 files changed, 10 insertions, 5 deletions
diff --git a/test/runtest b/test/runtest index 484b799e9..41531609e 100755 --- a/test/runtest +++ b/test/runtest @@ -923,8 +923,9 @@ RESET_AFTER_EXTRA_LINE_READ: # subsecond timstamp info in reported header-files s/^(-received_time_usec \.)\d{6}$/$1uuuuuu/; - # Postgres server takes varible time to shut down + # Postgres server takes varible time to shut down; lives in various places s/^waiting for server to shut down\.+ done$/waiting for server to shut down.... done/; + s/^\/.*postgres /POSTGRES /; } # ======== stderr ======== diff --git a/test/scripts/2610-MySQL/2610 b/test/scripts/2610-MySQL/2610 index 5c104f3fe..9a36f0763 100644 --- a/test/scripts/2610-MySQL/2610 +++ b/test/scripts/2610-MySQL/2610 @@ -4,19 +4,22 @@ # # first, populate a DB to test against sudo rm -fr DIR/mysql +echo Installing DB server dir perl system 'mysql_install_db --no-defaults --datadir=DIR/mysql --user=CALLER'; **** sudo rm test-stdout test-stderr # # start a db server +echo Starting DB server background DIR/bin.sys/mysqld --datadir=DIR/mysql --log-error=DIR/mysql/log --bind-address=* --port=PORT_N --socket=DIR/mysql/sock --pid-file=DIR/mysql/pidfile **** # # wait for db startup, insert some data +echo Waiting for DB server startup perl -system 'mysqladmin --protocol=TCP -P PORT_N --connect_timeout=1 --wait=5 -u root create test'; +system 'mysqladmin --protocol=TCP -P PORT_N --connect_timeout=2 --wait=5 -u root create test'; my $fh; open($fh, '-|', 'mysql --protocol=TCP -P PORT_N -u root -D test -e "select 1 from mysql.user where User = \'root\' and Host = \'HOSTIPV4\'"'); my $line = <$fh>; @@ -41,6 +44,7 @@ system 'mysql --protocol=TCP -P PORT_N -u root -D test \ GRANT ALL ON *.* TO \'CALLER\'@\'HOSTIPV4\'; \ "'; **** +echo Populated DB sudo rm test-stderr-server # # diff --git a/test/src/client.c b/test/src/client.c index be8b1cc0d..eef82ef57 100644 --- a/test/src/client.c +++ b/test/src/client.c @@ -224,7 +224,7 @@ if(!(bs = OCSP_response_get1_basic(rsp))) } -if (!(sk = chain_from_pem_file(ocsp_stapling))) +if (!(sk = chain_from_pem_file((const uschar *)ocsp_stapling))) { BIO_printf(arg, "error in cert setup\n"); return 0; @@ -720,7 +720,7 @@ int rc; else if (strncmp(CS outbuffer, "<<< ", 4) == 0) { FILE * new_f; - if (!(new_f = fopen(outbuffer+4 , "r"))) + if (!(new_f = fopen((const char *)outbuffer+4 , "r"))) { printf("Unable to open '%s': %s", inptr, strerror(errno)); exit(74); diff --git a/test/stdout/2620 b/test/stdout/2620 index 74b91abee..8afeec94d 100644 --- a/test/stdout/2620 +++ b/test/stdout/2620 @@ -1,5 +1,5 @@ pg_ctl: server is running (PID: pppp) -/usr/bin/postgres "-D" "TESTSUITE/pgsql/data" "-p" "1223" "-k" "TESTSUITE/pgsql" +POSTGRES "-D" "TESTSUITE/pgsql/data" "-p" "1223" "-k" "TESTSUITE/pgsql" INSERT 0 1 > Philip Hazel > Philip Hazel |