mirror of
https://github.com/correl/rebar.git
synced 2024-11-27 11:09:55 +00:00
Merge pull request #425 from tomas-abrahamsson/mock-gpb-and-protobuffs-in-inttest
Copy instead of rsync gpb and protobuffs inttest mocks
This commit is contained in:
commit
473d9fe145
4 changed files with 16 additions and 4 deletions
|
@ -48,11 +48,11 @@ files() ->
|
||||||
{copy, "rebar.config", "rebar.config"},
|
{copy, "rebar.config", "rebar.config"},
|
||||||
{copy, "include", "include"},
|
{copy, "include", "include"},
|
||||||
{copy, "src", "src"},
|
{copy, "src", "src"},
|
||||||
|
{copy, "mock", "deps"},
|
||||||
{create, "ebin/foo.app", app(foo, ?MODULES ++ ?GENERATED_MODULES)}
|
{create, "ebin/foo.app", app(foo, ?MODULES ++ ?GENERATED_MODULES)}
|
||||||
].
|
].
|
||||||
|
|
||||||
run(_Dir) ->
|
run(_Dir) ->
|
||||||
?assertMatch({ok, _}, retest_sh:run("./rebar prepare-deps", [])),
|
|
||||||
?assertMatch({ok, _}, retest_sh:run("./rebar clean", [])),
|
?assertMatch({ok, _}, retest_sh:run("./rebar clean", [])),
|
||||||
?assertMatch({ok, _}, retest_sh:run("./rebar compile", [])),
|
?assertMatch({ok, _}, retest_sh:run("./rebar compile", [])),
|
||||||
%% Foo includes test_gpb.hrl,
|
%% Foo includes test_gpb.hrl,
|
||||||
|
|
|
@ -8,7 +8,13 @@
|
||||||
|
|
||||||
{deps,
|
{deps,
|
||||||
[
|
[
|
||||||
{gpb, [], {rsync, "../../../inttest/proto_gpb/mock/gpb"}}
|
%% The dependency below to gpb is needed for "rebar compile" to
|
||||||
|
%% work, thus for the inttest to work, but the gpb that is actually
|
||||||
|
%% used in inttest is brought in from the inttest/proto_gpb/mock
|
||||||
|
%% subdirectory, not from the source below. The dependency is
|
||||||
|
%% needed, but the git url serves mostly as an example.
|
||||||
|
{gpb, [], {git, "git://github.com/tomas-abrahamsson/gpb",
|
||||||
|
{branch, "master"}}}
|
||||||
]}.
|
]}.
|
||||||
|
|
||||||
{proto_compiler, gpb}.
|
{proto_compiler, gpb}.
|
||||||
|
|
|
@ -48,11 +48,11 @@ files() ->
|
||||||
{copy, "rebar.config", "rebar.config"},
|
{copy, "rebar.config", "rebar.config"},
|
||||||
{copy, "include", "include"},
|
{copy, "include", "include"},
|
||||||
{copy, "src", "src"},
|
{copy, "src", "src"},
|
||||||
|
{copy, "mock", "deps"},
|
||||||
{create, "ebin/foo.app", app(foo, ?MODULES)}
|
{create, "ebin/foo.app", app(foo, ?MODULES)}
|
||||||
].
|
].
|
||||||
|
|
||||||
run(_Dir) ->
|
run(_Dir) ->
|
||||||
?assertMatch({ok, _}, retest_sh:run("./rebar prepare-deps", [])),
|
|
||||||
?assertMatch({ok, _}, retest_sh:run("./rebar clean", [])),
|
?assertMatch({ok, _}, retest_sh:run("./rebar clean", [])),
|
||||||
?assertMatch({ok, _}, retest_sh:run("./rebar compile", [])),
|
?assertMatch({ok, _}, retest_sh:run("./rebar compile", [])),
|
||||||
ok = check_beams_generated(),
|
ok = check_beams_generated(),
|
||||||
|
|
|
@ -8,7 +8,13 @@
|
||||||
|
|
||||||
{deps,
|
{deps,
|
||||||
[
|
[
|
||||||
{protobuffs, [], {rsync, "../../../inttest/proto_protobuffs/mock/protobuffs"}}
|
%% The dependency below to protobuffs is needed for "rebar compile" to
|
||||||
|
%% work, thus for the inttest to work, but the protobuffs that is actually
|
||||||
|
%% used in inttest is brought in from the inttest/proto_protobuffs/mock
|
||||||
|
%% subdirectory, not from the source below. The dependency is
|
||||||
|
%% needed, but the git url serves mostly as an example.
|
||||||
|
{protobuffs, [], {git, "git://github.com/basho/erlang_protobuffs",
|
||||||
|
{branch, "master"}}}
|
||||||
]}.
|
]}.
|
||||||
|
|
||||||
%% The default proto compiler is protobuffs
|
%% The default proto compiler is protobuffs
|
||||||
|
|
Loading…
Reference in a new issue