Skip to content
This repository has been archived by the owner on Jan 19, 2022. It is now read-only.

Commit

Permalink
Updated integration test
Browse files Browse the repository at this point in the history
  • Loading branch information
riverrun committed Jan 9, 2017
1 parent bf62df5 commit 103545c
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 10 deletions.
Binary file modified installer/archives/openmaize_phx-2.7.0.ez
Binary file not shown.
18 changes: 9 additions & 9 deletions installer/integration_test/openmaize_phoenixauth_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,17 @@ set -x

LOG="../openmaize_phoenixauth_test.log"

function new_project {
cd alibaba || exit $?
function enter_cave {
echo -e "\nDATE: $(date) OPTIONS: $@\n" >> $LOG
echo y | mix openmaize.phx $@
}

function edit_mix_config {
sed -i 's/username: "postgres"/username: "dev"/g' config/dev.exs config/test.exs
sed -i 's/password: "postgres"/password: System.get_env("POSTGRES_PASS")/g' config/dev.exs config/test.exs
sed -i 's/:postgrex]/:postgrex, :openmaize]/g' mix.exs
sed -i 's/{:postgrex, ">= 0.0.0"},/{:postgrex, ">= 0.0.0"},\n {:openmaize, "~> 2.7"},/g' mix.exs
}

function enter_cave {
sed -i 's/{:postgrex, ">= 0.0.0"},/{:postgrex, ">= 0.0.0"},\n {:openmaize, "~> 2.6"},/g' mix.exs
mix deps.get
echo -e "\nDATE: $(date) OPTIONS: $@\n" >> $LOG
echo y | mix openmaize.phx $@
}

function run_tests {
Expand All @@ -28,8 +27,9 @@ function clean {
}

function openmaize_project {
new_project
cd alibaba || exit $?
enter_cave $@
edit_mix_config
run_tests
clean
}
Expand Down
8 changes: 7 additions & 1 deletion installer/phoenix/lib/openmaize_phx.ex
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,13 @@ defmodule Mix.Tasks.Openmaize.Phx do
You might also need to edit the database details in the `config`
files.
After that, run `mix test` to run all the tests.
Then, to run the tests:
mix test
And to start the server:
mix phoenix.server
If you are not using "username" or "email" to index / identify
the user, and if any of the session_controller tests fail, you
Expand Down

0 comments on commit 103545c

Please sign in to comment.