@@ -48,9 +48,15 @@ defmodule Mix.Tasks.Igniter.InstallTest do
4848
4949 describe "installing a new project" do
5050 test "basic installer works" do
51+ # get the unsuppressed compilation of `test_project`'s deps out of the way,
52+ # so that the only remaining output is the installer's own
5153 cmd! ( "mix" , [ "deps.compile" ] , cd: "test_project" )
5254 output = cmd! ( "mix" , [ "igniter.install" , "jason" ] , cd: "test_project" )
53- refute String . contains? ( output , "jason\n Compiling" )
55+
56+ # each step is reported as a spinner line, with its output suppressed
57+ assert output =~ "fetching deps"
58+ refute output =~ "fetching deps:"
59+ refute output =~ "compiling jason:"
5460 end
5561
5662 test "does not report success when installation is declined" do
@@ -72,8 +78,13 @@ defmodule Mix.Tasks.Igniter.InstallTest do
7278 end
7379
7480 test "displays additional information with `--verbose` option" do
81+ cmd! ( "mix" , [ "deps.compile" ] , cd: "test_project" )
7582 output = cmd! ( "mix" , [ "igniter.install" , "jason" , "--verbose" ] , cd: "test_project" )
76- assert String . contains? ( output , "jason\n Compiling" )
83+
84+ # each step names itself and passes its output through, rather than spinning
85+ assert output =~ "compile:"
86+ assert output =~ "fetching deps:"
87+ assert output =~ "compiling jason:"
7788 end
7889
7990 test "rerunning the same installer lets you know the dependency was not changed" do
0 commit comments