Skip to content

Commit

Permalink
removing sqlcmd
Browse files Browse the repository at this point in the history
  • Loading branch information
mjaric committed Feb 26, 2017
1 parent 8dcf849 commit 941f2dc
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
9 changes: 4 additions & 5 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,16 @@ dependencies:
- asdf plugin-add elixir https://github.com/HashNuke/asdf-elixir.git
- erlang_version=$(awk '/erlang/ { print $2 }' .tool-versions) && asdf install erlang ${erlang_version}
- elixir_version=$(awk '/elixir/ { print $2 }' .tool-versions) && asdf install elixir ${elixir_version}
- mix local.hex --force
- mix local.rebar --force
- yes | mix deps.get
- curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
- curl https://packages.microsoft.com/config/ubuntu/16.04/prod.list | sudo tee /etc/apt/sources.list.d/msprod.list
- sudo apt-get update
- sudo apt-get install mssql-tools unixodbc-dev
- echo 'export PATH="$PATH:/opt/mssql-tools/bin"' >> ~/.bashrc
- source ~/.bashrc
- docker run -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=Som320923!!!2932#ePassword2938474' -p 1433:1433 -d microsoft/mssql-server-linux
- sqlcmd -S localhost -U SA -P Som320923!!!2932#ePassword2938474 -Q "CREATE LOGIN mssql WITH PASSWORD = 'mssql'; CREATE USER mssql FOR LOGIN mssql; sp_addsrvrolemember 'mssql', 'sysadmin'"
- docker run -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=${SQL_PASSWORD}' -p 1433:1433 -d microsoft/mssql-server-linux
- mix local.hex --force
- mix local.rebar --force
- mix deps.get
cache_directories:
- ~/.asdf
- ~/.mix
Expand Down
4 changes: 2 additions & 2 deletions test/storage_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ defmodule Tds.Ecto.StorageTest do
def params do
[database: "storage_mgt",
pool: Ecto.Adapters.SQL.Sandbox,
username: "mssql",
password: "mssql",
username: "sa",
password: System.get_env("SQL_PASSWORD") || "mssql",
hostname: "localhost"]
end

Expand Down
8 changes: 4 additions & 4 deletions test/test_helper.exs
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ Application.put_env(:ecto, TestRepo,
filter_null_on_unique_indexes: true,
adapter: Tds.Ecto,
hostname: "localhost",
username: "mssql",
password: "mssql",
username: "sa",
password: System.get_env("SQL_PASSWORD") || "mssql",
database: "ecto_test",
pool: Ecto.Adapters.SQL.Sandbox,
pool_size: 10,
Expand All @@ -43,8 +43,8 @@ Application.put_env(:ecto, PoolRepo,
adapter: Tds.Ecto,
pool: pool,
hostname: "localhost",
username: "mssql",
password: "mssql",
username: "sa",
password: System.get_env("SQL_PASSWORD") || "mssql",
database: "ecto_test",
pool_size: 10)

Expand Down

0 comments on commit 941f2dc

Please sign in to comment.