Skip to content

Commit

Permalink
Add test alias to mix.exs
Browse files Browse the repository at this point in the history
  • Loading branch information
wintermeyer committed Oct 8, 2023
1 parent 3608038 commit 6413b1d
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions modules/ROOT/pages/ash/postgresql/phoenix.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,36 @@ defmodule App.DataCase do
end
----

And we have to add a new alias for the tests:

[source,elixir,title='mix.exs']
----
[...]
defp aliases do
[
setup: ["deps.get", "assets.setup", "assets.build"],
"assets.setup": ["tailwind.install --if-missing", "esbuild.install --if-missing"],
"assets.build": ["tailwind default", "esbuild default"],
"assets.deploy": ["tailwind default --minify", "esbuild default --minify", "phx.digest"],
test: ["ash_postgres.create --quiet", "ash_postgres.migrate --quiet", "test"] <1>
]
end
[...]
----

<1> Add this line.

Now we can run the tests:

```elixir
$ mix test
.....
Finished in 0.06 seconds (0.02s async, 0.04s sync)
5 tests, 0 failures

Randomized with seed 503191
```

### Create the Database

Assuming that you have https://www.postgresql.org[PostgreSQL] installed
Expand Down

0 comments on commit 6413b1d

Please sign in to comment.