[99s-extend] usage of make_* command

Loïc Hoguin essen at ninenines.eu
Thu Mar 6 15:51:58 CET 2014


Sorry I meant ./test/ not ./tests/

But yes. That's how OTP does it.

On 03/06/2014 03:50 PM, Anton Koval' wrote:
> Thank you for answer.
> Is it common way (for OTP-based application) to store tests in `tests`
> subdirectory rather then in `src/tests/`?
>
>
> On Thu, Mar 6, 2014 at 4:40 PM, Loïc Hoguin <essen at ninenines.eu
> <mailto:essen at ninenines.eu>> wrote:
>
>     Tests should be in ./tests, not ./src/tests.
>
>     If you put them in ./tests everything you mentioned will work.
>
>
>     On 03/03/2014 09:49 PM, Anton Koval' wrote:
>
>         Hello,
>
>         I have next structure of my project:
>         .
>         ├── deps
>         │   ├── cowboy
>         │   ├── cowlib
>         │   ├── erlang_iconv
>         │   ├── erlydtl
>         │   ├── mochiweb_xpath
>         │   └── ranch
>         ├── ebin
>         │   ├── fetchers.beam
>         │   ├── parsers.beam
>         │   └── wasearch_sup.beam
>         ├── erlang.mk <http://erlang.mk> <http://erlang.mk>
>
>         ├── Makefile
>         ├── _rel
>         │   └── ....
>         ├── relx
>         ├── relx.config
>         ├── src
>         │   ├── fetchers.erl
>         │   ├── main_handler.erl
>         │   ├── parsers.erl
>         │   ├── tests
>         │   │   ├── parsers_SUITE_data
>         │   │   ├── parsers_SUITE.erl
>         │   │   ├── ....
>         │   ├── wasearch_app.erl
>         │   ├── wasearch.app.src
>         │   └── wasearch_sup.erl
>         └── templates
>               └── index.dtl
>
>         I would prefer to store tests not in `src` directory but rather in
>         `tests` subdirectory.
>         Erlang.mk README says: You can run an individual test suite by
>         using the
>         special |test_*| targets. For example if you have a common_test
>         suite
>         named |spdy| and you want to run only this suite and not the
>         others, you
>         can use the |make test_spdy| command.
>         And of course `make test_parsers`  returns `no rule to make
>         target` error.
>         Is there a way to run suites from custom directory with
>         `make_<mod_name_with_suite>` command?
>
>
>         _________________________________________________
>         Extend mailing list
>         Extend at lists.ninenines.eu <mailto:Extend at lists.ninenines.eu>
>         https://lists.ninenines.eu/__listinfo/extend
>         <https://lists.ninenines.eu/listinfo/extend>
>
>
>     --
>     Loïc Hoguin
>     http://ninenines.eu
>
>

-- 
Loïc Hoguin
http://ninenines.eu



More information about the Extend mailing list