clojure maven plugin: clojure tests succeed when using mvn clojure:test but NOT during test phase when using mvn install

37 views
Skip to first unread message

Horace

unread,
Jul 25, 2013, 11:58:38 AM7/25/13
to clojure-ma...@googlegroups.com
Hi Everybody,
I am using the clojure maven plugin to build a project. The projects contains a test, let us say mytest.clj, that has a content like the following:

    (def ^:dynamic *server*
      (create-server "tcp://bla.bla:9999"))
   
    (deftest blabla1...)
    (deftest blabla2...)


If I run  mvn clojure:test , the build runs successfully.

 But If I run mvn install  then when the test phase is reached, the server declared in mytest.clj is started. After that start, nothing more happens: the clojure test script seems to be frozen and building of the project cannot be continued (without any error message). Although, as already said,  mvn clojure:test  runs successfully for the same project.

Does somebody know how to solve this problem?

Any help will be appreciated.
Thx in advance
Regards

Horace

P.S: I can use the standard ***mvn install*** to compile and test the clojure sources because my project's packaging is configured as a 'clojure' one in *pom.xml*. The consequence of it, is that the clojure maven plugin then automatically binds itself  to the maven phases compile, test and test-compile.

Mark Derricutt

unread,
Oct 16, 2013, 9:10:48 PM10/16/13
to clojure-ma...@googlegroups.com
Did you ever find a solution to this problem at all?

From memory I suggested doing a thread-dump and seeing where the code was blocking, but I don't think I ever heard anything further?

On 26 Jul 2013, at 3:58, Horace wrote:

> Hi Everybody,
> I am using the *clojure maven plugin* to build a project. The projects
> contains a test, let us say *mytest.clj*, that has a content like the
> following:
>
> (def ^:dynamic *server*
> (create-server "tcp://bla.bla:9999"))
>
> (deftest blabla1...)
> (deftest blabla2...)
>
> If I run *mvn clojure:test* , the build runs successfully.
>
> But If I run *mvn install* then when the *test phase is reached*, the
> server declared in *mytest.clj* is started. After that start, nothing more
> happens: the clojure test script seems to be frozen and building of the
> project cannot be continued (without any error message). Although, as
> already said, *mvn clojure:test* runs successfully for the same project.
>
> Does somebody know how to solve this problem?
>
> Any help will be appreciated.
> Thx in advance
> Regards
>
> Horace
>
> P.S: I can use the standard ***mvn install*** to compile and test the
> clojure sources because my project's packaging is configured as a 'clojure'
> one in *pom.xml*. The consequence of it, is that the clojure maven plugin
> then automatically binds itself to the maven phases compile, test and
> test-compile.
>
> --
>
> ---
> You received this message because you are subscribed to the Google Groups "Clojure Maven Plugin" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to clojure-maven-pl...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
signature.asc
Reply all
Reply to author
Forward
0 new messages