Eunit test generators
kennethstone at gmail.com
Fri Jul 22 19:08:33 EDT 2011
I really like the pattern of keeping my tests in a separate file, a
"foo_test.hrl" or "foo_test.erl", and I couldn't seem to get rebar to like
that pattern either.
On Fri, Jul 22, 2011 at 6:05 PM, Garrett Smith <g at rre.tt> wrote:
> On Fri, Jul 22, 2011 at 4:39 PM, Garrett Smith <g at rre.tt> wrote:
> > I have a test module that uses a test generator -- I need a
> > setup/cleanup fixture.
> > I'm able to run the test fine when I explicitly specify the suite:
> > rebar eunit suite=my_tests
> > However, when I run the general command:
> > rebar eunit
> > the test isn't executed.
> This has nothing to do with generators.
> This is a test that doesn't have a corresponding module. E.g. the test
> is "foo_tests" but there's no "foo" module.
> I raised this issue earlier and the line is that "this is the way eunit
> Not really. If I want to run a test module under eunit, I can simply
> call eunit:test/1,2.
> Is there some reason rebar doesn't just run everything in "test"? If
> something can't be tested because it doesn't export test/0, just skip
> rebar mailing list
> rebar at lists.basho.com
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rebar