My personal preference would be src/mock/... structured like
src/test/... and be able to build an output artifact jar with classifier
"mock" as part of the normal build.  To do this, unfortunately, requires
resolution of MCOMPILER-13.

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Carlos
Sanchez
Sent: Thursday, February 09, 2006 17:06
To: Maven Developers List
Subject: Creating mock objects for core components


Hi,

I think it'd be useful to create a project with mock objects, eg
Artifact, MavenProject,... as I have already seen some implementations
in plugins test (eg. jar plugin), to avoid repetition and make it easy
to test stuff. it doesn't mean start making mocks right now, but
setting up a place where to put the stuff as we make it.

What's the suggested approach?

a) create a new project with only mocks for each project already
existing
  - maven-model-mock
  - maven-artifact-mock
  pros: clean api
  cons: many new projects

b) put the mocks in the test folder and deploy the test jars
  pros: no new projects, mocks are close to implementations, same
lifecycle
  cons: dirty api, tests also included in jar, we should follow
backwards compatibility in tests, no way to say what is supposed to be
used and what not

c) create a new folder src/mock/main (and src/mock/test if we really
need it)
  pros: both of the other two
  cons: change directory structure now ?

WDYT?

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to