Skip to content

Commit

Permalink
[#141] Test MSSQL 19 support
Browse files Browse the repository at this point in the history
  • Loading branch information
javrasya committed Mar 16, 2020
1 parent 4c0620b commit 4c4b833
Show file tree
Hide file tree
Showing 7 changed files with 58 additions and 4 deletions.
4 changes: 4 additions & 0 deletions .travis.yml
Expand Up @@ -51,6 +51,10 @@ matrix:
env: TOXENV=py36-dj2.2-mssql17
services:
- docker
- python: "3.6"
env: TOXENV=py36-dj2.2-mssql19
services:
- docker

install:
- curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
Expand Down
3 changes: 2 additions & 1 deletion MANIFEST.in
@@ -1,2 +1,3 @@
include README.md
include *.txt
include *.txt
include river/sql/mssql/get_available_approvals.sql
20 changes: 20 additions & 0 deletions README.rst
Expand Up @@ -108,6 +108,14 @@ Supported (Tested) Databases:
| 8.0 |||
+------------+--------+---------+

+------------+--------+---------+
| MSSQL | Tested | Support |
+------------+--------+---------+
| 19 |||
+------------+--------+---------+
| 17 |||
+------------+--------+---------+


Usage
-----
Expand Down Expand Up @@ -242,6 +250,18 @@ out of the box. All you need to do is to run;
python manage.py migrate river
3.1.X to 3.2.X
^^^^^^^^^^^^^^

``django-river`` started to support **Microsoft SQL Server 17 and 19** after version 3.2.0 but the previous migrations didn't get along with it. We needed to reset all
the migrations to have fresh start. If you have already migrated to version `3.1.X` all you need to do is to pull your migrations back to the beginning.


.. code:: bash
python manage.py migrate --fake river zero
python manage.py migrate --fake river
FAQ
---

Expand Down
1 change: 1 addition & 0 deletions docs/migration/index.rst
Expand Up @@ -7,5 +7,6 @@ Migration Guide
:maxdepth: 2

migration_2_to_3
migration_31_to_32
hooking

13 changes: 13 additions & 0 deletions docs/migration/migration_31_to_32.rst
@@ -0,0 +1,13 @@
.. _migration_31_to_32:

3.1.X to 3.2.X
==============

``django-river`` started to support **Microsoft SQL Server 17 and 19** after version 3.2.0 but the previous migrations didn't get along with it. We needed to reset all
the migrations to have fresh start. If you have already migrated to version `3.1.X` all you need to do is to pull your migrations back to the beginning.


.. code:: bash
python manage.py migrate --fake river zero
python manage.py migrate --fake river
7 changes: 7 additions & 0 deletions docs/overview.rst
Expand Up @@ -45,6 +45,13 @@ Supported (Tested) Databases:
| 8.0 |||
+------------+--------+---------+

+------------+--------+---------+
| MSSQL | Tested | Support |
+------------+--------+---------+
| 19 |||
+------------+--------+---------+
| 17 |||
+------------+--------+---------+

Example Scenarios
-----------------
Expand Down
14 changes: 11 additions & 3 deletions tox.ini
Expand Up @@ -4,7 +4,7 @@ envlist = {py27,py34}-{dj1.11}-{sqlite3},
{py36}-{dj1.11,dj2.0,dj2.1,dj2.2,dj3.0}-{sqlite3},
{py36}-{dj2.2}-{postgresql9,postgresql10,postgresql11,postgresql12},
{py36}-{dj2.2}-{mysql8.0},
{py36}-{dj2.2}-{msqsql17},
{py36}-{dj2.2}-{msqsql17,mssql19},
cov,

[testenv]
Expand All @@ -15,6 +15,7 @@ docker =
postgresql12: postgres:12-alpine
mysql8.0: mysql:8.0
mssql17: mcr.microsoft.com/mssql/server:2017-latest
mssql19: mcr.microsoft.com/mssql/server:2017-latest
dockerenv =
POSTGRES_USER=river
POSTGRES_PASSWORD=river
Expand All @@ -30,7 +31,7 @@ setenv =
sqlite3: DJANGO_SETTINGS_MODULE=settings.with_sqlite3
postgresql9,postgresql10,postgresql11,postgresql12: DJANGO_SETTINGS_MODULE=settings.with_postgresql
mysql8.0: DJANGO_SETTINGS_MODULE=settings.with_mysql
mssql17: DJANGO_SETTINGS_MODULE=settings.with_mssql
mssql17,mssql19: DJANGO_SETTINGS_MODULE=settings.with_mssql
deps =
pytest-django>3.1.2
pytest-cov
Expand All @@ -42,7 +43,7 @@ deps =
dj3.0: Django>=3.0,<3.1.0
postgresql9,postgresql10,postgresql11,postgresql12: psycopg2
mysql8.0: mysqlclient
mssql17: django-mssql-backend
mssql17,mssql19: django-mssql-backend
commands =
py.test --junitxml=../junit-{envname}.xml
python manage.py behave
Expand All @@ -69,4 +70,11 @@ healthcheck_cmd = '/opt/mssql-tools/bin/sqlcmd -S localhost -U sa -P River@Crede
healthcheck_interval = 10
healthcheck_start_period = 10
healthcheck_retries = 10
healthcheck_timeout = 3

[docker:mcr.microsoft.com/mssql/server:2019-latest]
healthcheck_cmd = '/opt/mssql-tools/bin/sqlcmd -S localhost -U sa -P River@Credentials -Q "SELECT 1" || exit 1'
healthcheck_interval = 10
healthcheck_start_period = 10
healthcheck_retries = 10
healthcheck_timeout = 3

0 comments on commit 4c4b833

Please sign in to comment.