aboutsummaryrefslogtreecommitdiffstats
path: root/test/rlx_release_SUITE.erl
diff options
context:
space:
mode:
Diffstat (limited to 'test/rlx_release_SUITE.erl')
-rw-r--r--test/rlx_release_SUITE.erl12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/rlx_release_SUITE.erl b/test/rlx_release_SUITE.erl
index ccf5a8f..aea28f2 100644
--- a/test/rlx_release_SUITE.erl
+++ b/test/rlx_release_SUITE.erl
@@ -383,6 +383,11 @@ overlay_release(Config) ->
ConfigFile = filename:join([LibDir1, "relx.config"]),
OverlayVars = filename:join([LibDir1, "vars.config"]),
Template = filename:join([LibDir1, "test_template"]),
+ TestDir = "first_test_dir",
+ TestFile = "test_file",
+ TestDirFull = filename:join([LibDir1, TestDir]),
+ TestFileFull = filename:join(TestDirFull, TestFile),
+ SecondTestDir = "second_test_dir",
write_config(ConfigFile,
[{overlay_vars, OverlayVars},
{overlay, [{mkdir, "{{target_dir}}/fooo"},
@@ -390,6 +395,8 @@ overlay_release(Config) ->
"{{target_dir}}/{{foo_dir}}/vars.config"},
{copy, OverlayVars,
"{{target_dir}}/{{yahoo}}/"},
+ {copy, TestDirFull,
+ "{{target_dir}}/"++SecondTestDir++"/"},
{template, Template,
"{{target_dir}}/test_template_resolved"}]},
{release, {foo, "0.0.1"},
@@ -402,6 +409,9 @@ overlay_release(Config) ->
{yahoo3, [{bar, "{{yahoo}}/{{yahoo2.foo}}"}]},
{foo_dir, "foodir"}]),
+ ok = rlx_util:mkdir_p(TestDirFull),
+ ok = file:write_file(TestFileFull, test_template_contents()),
+
TemplateFile = filename:join([LibDir1, "test_template"]),
ok = file:write_file(TemplateFile, test_template_contents()),
{ok, FileInfo} = file:read_file_info(TemplateFile),
@@ -426,6 +436,8 @@ overlay_release(Config) ->
?assert(ec_file:exists(filename:join(OutputDir, "fooo"))),
?assert(ec_file:exists(filename:join([OutputDir, "foodir", "vars.config"]))),
?assert(ec_file:exists(filename:join([OutputDir, "yahoo", "vars.config"]))),
+ io:format("DirFile ~p~n", [filename:join([OutputDir, SecondTestDir, TestDir, TestFile])]),
+ ?assert(ec_file:exists(filename:join([OutputDir, SecondTestDir, TestDir, TestFile]))),
TemplateData = case file:consult(filename:join([OutputDir, "test_template_resolved"])) of
{ok, Details} ->