forax / pro

A Java build tool that works seamlessly with modules
GNU General Public License v3.0
103 stars 15 forks source link

Plugin: tester #27

Closed sormuras closed 7 years ago

sormuras commented 7 years ago

plugin tester

See work-in-progress output: https://travis-ci.org/forax/pro/builds/225994278

~todo~ done

sormuras commented 7 years ago

@forax Is directory ./deps the right place to put test scope libraries? See https://github.com/forax/pro/pull/27/commits/3079fdde5684bac47cfd085fcd0304e5beed5f45

forax commented 7 years ago

yes, source dependencies and test dependencies are both stored in deps, given that tests have a different module-info than sources, the module system will not mix then when compiling or running.

sormuras commented 7 years ago

[...] the module system will not mix then when compiling or running.

But my mind system sometimes does... ;)

sormuras commented 7 years ago

I'll address the last two open tasks today. I'm not sure, whether Move "test.pro" script to Bootstrap is a ... good move. Maybe an extra build script for tests is clearer separation of concerns. What do you think?

forax commented 7 years ago

You need to define a Facade interface to extract values from the "convention", like https://github.com/forax/pro/blob/master/src/main/java/com.github.forax.pro.plugin.compiler/com/github/forax/pro/plugin/compiler/ConventionFacade.java so you can extract it in execute.

Technically, each plugin defines an intermediary values that allows to override moduleExplodedPath but only for this plugin, like this: https://github.com/forax/pro/blob/master/src/main/java/com.github.forax.pro.plugin.compiler/com/github/forax/pro/plugin/compiler/CompilerPlugin.java#L53 and https://github.com/forax/pro/blob/master/src/main/java/com.github.forax.pro.plugin.compiler/com/github/forax/pro/plugin/compiler/CompilerPlugin.java#L111

sormuras commented 7 years ago

Like done in https://github.com/forax/pro/pull/27/commits/4db5328bcf11d02938eeb05175637237dfc976a7 ?

forax commented 7 years ago

yes !

sormuras commented 7 years ago

With the questionable task "Move test.pro script to Bootstrap" removed from the todo list, this PR feels like ... done. From my point of view. Anything big left open, @forax ?

Cleanup, polishing and making tester really configurable is up to you. ✨ (-: