Add tests for pg@9.2 on travis
This commit is contained in:
parent
b9f8011dab
commit
a8cfa18f09
8
Makefile
8
Makefile
@ -7,7 +7,7 @@ params := $(connectionString)
|
|||||||
node-command := xargs -n 1 -I file node file $(params)
|
node-command := xargs -n 1 -I file node file $(params)
|
||||||
|
|
||||||
.PHONY : test test-connection test-integration bench test-native \
|
.PHONY : test test-connection test-integration bench test-native \
|
||||||
build/default/binding.node jshint
|
build/default/binding.node jshint upgrade-pg
|
||||||
|
|
||||||
all:
|
all:
|
||||||
npm install
|
npm install
|
||||||
@ -20,6 +20,12 @@ test: test-unit
|
|||||||
|
|
||||||
test-all: jshint test-unit test-integration test-native test-binary
|
test-all: jshint test-unit test-integration test-native test-binary
|
||||||
|
|
||||||
|
test-travis: test-all upgrade-pg test-integration test-native test-binary
|
||||||
|
|
||||||
|
upgrade-pg:
|
||||||
|
@chmod 755 script/travis-pg-9.2-install.sh
|
||||||
|
@./script/travis-pg-9.2-install.sh
|
||||||
|
|
||||||
bench:
|
bench:
|
||||||
@find benchmark -name "*-bench.js" | $(node-command)
|
@find benchmark -name "*-bench.js" | $(node-command)
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
"semver": "~1.1.4"
|
"semver": "~1.1.4"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "make test-all connectionString=pg://postgres@localhost:5432/postgres",
|
"test": "make test-travis connectionString=pg://postgres@localhost:5432/postgres",
|
||||||
"prepublish": "rm -r build || (exit 0)",
|
"prepublish": "rm -r build || (exit 0)",
|
||||||
"install": "node-gyp rebuild || (exit 0)"
|
"install": "node-gyp rebuild || (exit 0)"
|
||||||
},
|
},
|
||||||
|
18
script/travis-pg-9.2-install.sh
Executable file
18
script/travis-pg-9.2-install.sh
Executable file
@ -0,0 +1,18 @@
|
|||||||
|
#! /usr/bin/env bash
|
||||||
|
#sudo cat /etc/postgresql/9.1/main/pg_hba.conf
|
||||||
|
#sudo cat /etc/postgresql/9.1/main/pg_ident.conf
|
||||||
|
#sudo cat /etc/postgresql/9.1/main/postgresql.conf
|
||||||
|
sudo /etc/init.d/postgresql stop
|
||||||
|
sudo apt-get -y --purge remove postgresql
|
||||||
|
echo "yes" | sudo add-apt-repository ppa:pitti/postgresql
|
||||||
|
sudo apt-get update -qq
|
||||||
|
sudo apt-get -q -y -o Dpkg::Options::=--force-confdef install postgresql-9.2 postgresql-contrib-9.2
|
||||||
|
sudo chmod 777 /etc/postgresql/9.2/main/pg_hba.conf
|
||||||
|
sudo echo "local all postgres trust" > /etc/postgresql/9.2/main/pg_hba.conf
|
||||||
|
sudo echo "local all all trust" >> /etc/postgresql/9.2/main/pg_hba.conf
|
||||||
|
sudo echo "host all all 127.0.0.1/32 trust" >> /etc/postgresql/9.2/main/pg_hba.conf
|
||||||
|
sudo echo "host all all ::1/128 trust" >> /etc/postgresql/9.2/main/pg_hba.conf
|
||||||
|
sudo echo "host all all 0.0.0.0/0 trust" >> /etc/postgresql/9.2/main/pg_hba.conf
|
||||||
|
sudo echo "host all all 0.0.0.0 255.255.255.255 trust" >> /etc/postgresql/9.2/main/pg_hba.conf
|
||||||
|
sudo /etc/init.d/postgresql restart
|
||||||
|
node script/create-test-tables.js pg://postgres@127.0.0.1:5432/postgres
|
Loading…
Reference in New Issue
Block a user