Skip to content

Commit a7f95b2

Browse files
committed
Make 4-2-stable branch test'able.
1 parent 47091d2 commit a7f95b2

File tree

8 files changed

+127
-8
lines changed

8 files changed

+127
-8
lines changed

.travis.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
sudo: required
2+
cache: bundler
3+
services:
4+
- docker
5+
env:
6+
global:
7+
- TINYTDS_VERSION=1.1.0
8+
- ACTIVERECORD_UNITTEST_HOST=localhost
9+
- ACTIVERECORD_UNITTEST_DATASERVER=localhost
10+
rvm:
11+
- 2.2.5
12+
- 2.3.1
13+
before_install:
14+
- export PATH=/opt/local/bin:$PATH
15+
- docker info
16+
- sudo ./test/bin/setup.sh
17+
- sudo ./test/bin/install-openssl.sh
18+
- openssl version
19+
- sudo ./test/bin/install-freetds.sh
20+
- tsql -C
21+
install:
22+
- export PATH=/opt/local/bin:$PATH
23+
- gem install bundler
24+
- bundle --version
25+
- bundle install
26+
script:
27+
- bundle exec rake

README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
11

22
# ActiveRecord SQL Server Adapter. For SQL Server 2012 And Higher.
33

4-
[![Build status](https://ci.appveyor.com/api/projects/status/mtgbx8f57vr7k2qa/branch/master?svg=true)](https://ci.appveyor.com/project/rails-sqlserver/activerecord-sqlserver-adapter/branch/master) [![Gem Version](http://img.shields.io/gem/v/activerecord-sqlserver-adapter.svg?style=flat)](https://rubygems.org/gems/activerecord-sqlserver-adapter) [![Gitter chat](https://img.shields.io/badge/%E2%8A%AA%20GITTER%20-JOIN%20CHAT%20%E2%86%92-brightgreen.svg?style=flat)](https://gitter.im/rails-sqlserver/activerecord-sqlserver-adapter)
4+
* [![TravisCI](https://travis-ci.org/rails-sqlserver/activerecord-sqlserver-adapter.svg?branch=4-2-stable)](https://travis-ci.org/rails-sqlserver/activerecord-sqlserver-adapter) - TravisCI
5+
* [![CircleCI](https://circleci.com/gh/rails-sqlserver/activerecord-sqlserver-adapter/tree/4-2-stable.svg?style=svg)](https://circleci.com/gh/rails-sqlserver/activerecord-sqlserver-adapter/tree/4-2-stable) - CircleCI
6+
* [![Build Status](https://ci.appveyor.com/api/projects/status/mtgbx8f57vr7k2qa/branch/4-2-stable?svg=true)](https://ci.appveyor.com/project/rails-sqlserver/activerecord-sqlserver-adapter/branch/4-2-stable) - Appveyor
7+
* [![Gem Version](http://img.shields.io/gem/v/activerecord-sqlserver-adapter.svg)](https://rubygems.org/gems/activerecord-sqlserver-adapter) - Gem Version
8+
* [![Dependency Status](https://dependencyci.com/github/rails-sqlserver/activerecord-sqlserver-adapter/badge)](https://dependencyci.com/github/rails-sqlserver/activerecord-sqlserver-adapter) - Dependency Status
9+
* [![Gitter chat](https://img.shields.io/badge/%E2%8A%AA%20GITTER%20-JOIN%20CHAT%20%E2%86%92-brightgreen.svg?style=flat)](https://gitter.im/rails-sqlserver/activerecord-sqlserver-adapter) - Community
510

611
![kantishna-wide](https://cloud.githubusercontent.com/assets/2381/5895051/aa6a57e0-a4e1-11e4-95b9-23627af5876a.jpg)
712

appveyor.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@ init:
22
- SET PATH=C:\Ruby%ruby_version%\bin;%PATH%
33
- SET PATH=C:\MinGW\msys\1.0\bin;%PATH%
44
- SET RAKEOPT=-rdevkit
5-
- SET TESTOPTS='-v'
6-
- SET TINYTDS_VERSION=1.0.4
5+
- SET TINYTDS_VERSION=1.1.0
76
clone_depth: 5
87
skip_tags: true
98
matrix:
@@ -12,7 +11,9 @@ install:
1211
- ps: Update-AppveyorBuild -Version "$(Get-Content $env:appveyor_build_folder\VERSION).$env:appveyor_build_number"
1312
- ruby --version
1413
- gem --version
15-
- bundle install --without odbc guard
14+
- bundle install
15+
- gem uninstall bcrypt
16+
- gem install bcrypt --platform=ruby
1617
build: off
1718
test_script:
1819
- powershell -File "%APPVEYOR_BUILD_FOLDER%\test\appveyor\dbsetup.ps1"
@@ -26,14 +27,13 @@ test_script:
2627
- timeout /t 4 /nobreak > NUL
2728
- sqlcmd -S ".\SQL2012SP1" -U sa -P Password12! -i %APPVEYOR_BUILD_FOLDER%\test\appveyor\dbsetup.sql
2829
- bundle exec rake test ACTIVERECORD_UNITTEST_DATASERVER="localhost\SQL2012SP1"
29-
- timeout /t 4 /nobreak > NUL
30-
- bundle exec rake test ACTIVERECORD_UNITTEST_HOST=%CI_AZURE_HOST% ACTIVERECORD_UNITTEST_PASS=%CI_AZURE_PASS% ACTIVERECORD_UNITTEST_AZURE=1
3130
environment:
3231
CI_AZURE_HOST:
3332
secure: VChrioaIWkf9iuuaSs4cryiA4honrADgZqNC0++begg=
3433
CI_AZURE_PASS:
3534
secure: cSQp8sk4urJYvq0utpsK+r7J+snJ2wpcdp8RdXJfB+w=
3635
matrix:
37-
- ruby_version: "200"
38-
- ruby_version: "22"
36+
- ruby_version: "23-x64"
37+
- ruby_version: "23"
3938
- ruby_version: "22-x64"
39+
- ruby_version: "22"

circle.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
general:
2+
branches:
3+
ignore:
4+
- /dev.*/
5+
6+
machine:
7+
environment:
8+
PATH: /opt/local/bin:${PATH}
9+
TINYTDS_VERSION: 1.1.0
10+
ACTIVERECORD_UNITTEST_HOST: localhost
11+
ACTIVERECORD_UNITTEST_DATASERVER: localhost
12+
services:
13+
- docker
14+
15+
dependencies:
16+
override:
17+
- sudo ./test/bin/install-openssl.sh
18+
- openssl version
19+
- sudo ./test/bin/install-freetds.sh
20+
- tsql -C
21+
- rvm-exec 2.2.5 bundle install
22+
- rvm-exec 2.3.1 bundle install
23+
24+
database:
25+
override:
26+
- echo "Hello"
27+
post:
28+
- docker info
29+
- ./test/bin/setup.sh
30+
31+
test:
32+
override:
33+
- rvm-exec 2.2.5 bundle exec rake test
34+
- rvm-exec 2.3.1 bundle exec rake test

test/bin/.keep

Whitespace-only changes.

test/bin/install-freetds.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#!/usr/bin/env bash
2+
3+
set -x
4+
set -e
5+
6+
FREETDS_VERSION=1.00.21
7+
8+
wget ftp://ftp.freetds.org/pub/freetds/stable/freetds-$FREETDS_VERSION.tar.gz
9+
tar -xzf freetds-$FREETDS_VERSION.tar.gz
10+
cd freetds-$FREETDS_VERSION
11+
./configure --prefix=/opt/local \
12+
--with-openssl=/opt/local \
13+
--with-tdsver=7.3
14+
make
15+
make install
16+
cd ..
17+
rm -rf freetds-$FREETDS_VERSION
18+
rm freetds-$FREETDS_VERSION.tar.gz

test/bin/install-openssl.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#!/usr/bin/env bash
2+
3+
set -x
4+
set -e
5+
6+
OPENSSL_VERSION=1.0.2j
7+
8+
wget https://www.openssl.org/source/openssl-$OPENSSL_VERSION.tar.gz
9+
tar -xzf openssl-$OPENSSL_VERSION.tar.gz
10+
cd openssl-$OPENSSL_VERSION
11+
./config --prefix=/opt/local
12+
make
13+
make install
14+
cd ..
15+
rm -rf openssl-$OPENSSL_VERSION
16+
rm openssl-$OPENSSL_VERSION.tar.gz

test/bin/setup.sh

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/usr/bin/env bash
2+
3+
set -x
4+
set -e
5+
6+
tag=1.2
7+
8+
docker pull metaskills/mssql-server-linux-rails:$tag
9+
10+
container=$(docker ps -a -q --filter ancestor=metaskills/mssql-server-linux-rails:$tag)
11+
if [[ -z $container ]]; then
12+
docker run -p 1433:1433 -d metaskills/mssql-server-linux-rails:$tag && sleep 10
13+
exit
14+
fi
15+
16+
container=$(docker ps -q --filter ancestor=metaskills/mssql-server-linux-rails:$tag)
17+
if [[ -z $container ]]; then
18+
docker start $container && sleep 10
19+
fi

0 commit comments

Comments
 (0)