On Mon, 29 Mar 2004, Niall Pemberton wrote:

> OK, I was wrong - but then its difficult to to debug with the wrong stack
> trace ;-)

Sorry. ;-) I keep forgetting that the console output from Maven for unit
tests is basically useless, and you need to look at the report files to
see what really happened. What I posted was from the console. ;-(

--
Martin Cooper


> The first failure is on testEmailFromPerl[1] - which has a trailing space  -
> the space causes isValidDomain() to return false when macthing against
> DOMAIN_PATTERN.
>
> The second failure is because "joe+" is passing isValidUser() when matching
> against USER_PATTERN when the test is expected to fail.
>
> I don't know enough about regexp or email formats to work out what needs to
> change.
>
> Niall
>
> ----- Original Message -----
> From: "Martin Cooper" <[EMAIL PROTECTED]>
> To: "Jakarta Commons Developers List" <[EMAIL PROTECTED]>
> Sent: Monday, March 29, 2004 5:44 AM
> Subject: Re: [Validator] Unit tests failing
>
>
> > On Mon, 29 Mar 2004, Niall Pemberton wrote:
> >
> > > I think its the ExceptionTest which is failing and it looks like it
> should
> > > from the code. There are three tests in ExceptionTest - only one has
> code to
> > > "pass" the test if it gets the Exception its expecting - the other two
> are
> > > set to "fail".
> > >
> > > The two test which have failures have code to "pass" the test if the
> > > expected Exception is received but its been commented out and replaced
> with
> > > "fail" code. Theres a note saying "This will be true in Validator 2.0"
> above
> > > the commented out code in one of the tests but that doesn't really
> explain
> > > why the tests have been set up to throw an exception and then "fail".
> > >
> > > I think the bugs are in the test!
> >
> > No, the problems I'm seeing are definitely in the e-mail tests. I've
> > attached the Maven rest reports for the e-mail and exception tests, in
> > which you can see that the former failed, while the latter succeeded.
> >
> > --
> > Martin Cooper
> >
> >
> > >
> > > Niall
> > >
> > >
> > > ----- Original Message -----
> > > From: "Martin Cooper" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Monday, March 29, 2004 2:46 AM
> > > Subject: [Validator] Unit tests failing
> > >
> > >
> > > > The e-mail test is failing for me, with the stack trace below.
> > > >
> > > > Ideas, anyone?
> > > >
> > > > --
> > > > Martin Cooper
> > > >
> > > >
> > > >     [junit] Running org.apache.commons.validator.EmailTest
> > > >     [junit] Tests run: 8, Failures: 2, Errors: 0, Time elapsed: 1.913
> sec
> > > >     [junit] [ERROR] TEST org.apache.commons.validator.EmailTest FAILED
> > > >     [junit] dir attribute ignored if running in the same VM
> > > >     [junit] Running org.apache.commons.validator.ExceptionTest Mar 28,
> > > > 2004 5:32:49 PM org.apache.commons.validator.ValidatorAction
> executeVali
> > > > dationMethod SEVERE: Unhandled exception thrown during validation:
> > > > RUNTIME-EXCEPTION java.lang.RuntimeException: RUNTIME-EXCEPTION
> > > >         at
> > > > org.apache.commons.validator.TestValidator.validateRaiseException(Tes
> > > > tValidator.java:53)
> > > >         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > > >         at
> > > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> > > > java:39)
> > > >         at
> > > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> > > > sorImpl.java:25)
> > > >         at java.lang.reflect.Method.invoke(Method.java:324)
> > > >         at
> > > > org.apache.commons.validator.ValidatorAction.executeValidationMethod(
> > > > ValidatorAction.java:570)
> > > >         at
> > > > org.apache.commons.validator.Field.validateForRule(Field.java:808)
> > > >         at org.apache.commons.validator.Field.validate(Field.java:887)
> > > >         at org.apache.commons.validator.Form.validate(Form.java:171)
> > > >         at
> > > > org.apache.commons.validator.Validator.validate(Validator.java:367)
> > > >         at
> > > > org.apache.commons.validator.ExceptionTest.testRuntimeException(Excep
> > > > tionTest.java:98)
> > > >         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > > >         at
> > > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> > > > java:39)
> > > >         at
> > > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> > > > sorImpl.java:25)
> > > >         at java.lang.reflect.Method.invoke(Method.java:324)
> > > >         at junit.framework.TestCase.runTest(TestCase.java:154)
> > > >         at junit.framework.TestCase.runBare(TestCase.java:127)
> > > >         at junit.framework.TestResult$1.protect(TestResult.java:106)
> > > >         at
> junit.framework.TestResult.runProtected(TestResult.java:124)
> > > >         at junit.framework.TestResult.run(TestResult.java:109)
> > > >         at junit.framework.TestCase.run(TestCase.java:118)
> > > >         at junit.framework.TestSuite.runTest(TestSuite.java:208)
> > > >         at junit.framework.TestSuite.run(TestSuite.java:203)
> > > >         at
> > > > org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUni
> > > > tTestRunner.java:325)
> > > >         at
> > > > org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.executeInVM(JU
> > > > nitTask.java:848)
> > > >         at
> > > > org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute(JUnitT
> > > > ask.java:556)
> > > >         at
> > > > org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute(JUnitT
> > > > ask.java:532)
> > > >         at org.apache.tools.ant.Task.perform(Task.java:341)
> > > >         at
> org.apache.commons.jelly.tags.ant.AntTag.doTag(AntTag.java:232)
> > > >         at
> org.apache.commons.jelly.impl.TagScript.run(TagScript.java:279)
> > > >         at
> > > > org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:135)
> > > >         at
> > > > org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:233)
> > > >         at
> org.apache.commons.jelly.tags.core.IfTag.doTag(IfTag.java:88)
> > > >         at
> org.apache.commons.jelly.impl.TagScript.run(TagScript.java:279)
> > > >         at
> > > > org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:135)
> > > >         at
> > > > org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:233)
> > > >         at
> > > > com.werken.werkz.jelly.GoalTag$1.performAction(GoalTag.java:128)
> > > >         at com.werken.werkz.Goal.fire(Goal.java:639)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:575)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at
> > > > org.apache.maven.plugin.PluginManager.attainGoals(PluginManager.java:
> 448)
> > > >         at
> > > > org.apache.maven.MavenSession.attainGoals(MavenSession.java:348)
> > > >         at org.apache.maven.cli.App.doMain(App.java:543)
> > > >         at org.apache.maven.cli.App.main(App.java:1109)
> > > >         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > > >         at
> > > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> > > > java:39)
> > > >         at
> > > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> > > > sorImpl.java:25)
> > > >         at java.lang.reflect.Method.invoke(Method.java:324)
> > > >         at com.werken.forehead.Forehead.run(Forehead.java:551)
> > > >         at com.werken.forehead.Forehead.main(Forehead.java:581) Mar
> 28,
> > > > 2004 5:32:50 PM org.apache.commons.validator.ValidatorAction
> executeVali
> > > > dationMethod SEVERE: Unhandled exception thrown during validation:
> > > > CHECKED-EXCEPTION java.lang.Exception: CHECKED-EXCEPTION
> > > >         at
> > > > org.apache.commons.validator.TestValidator.validateRaiseException(Tes
> > > > tValidator.java:56)
> > > >         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > > >         at
> > > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> > > > java:39)
> > > >         at
> > > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> > > > sorImpl.java:25)
> > > >         at java.lang.reflect.Method.invoke(Method.java:324)
> > > >         at
> > > > org.apache.commons.validator.ValidatorAction.executeValidationMethod(
> > > > ValidatorAction.java:570)
> > > >         at
> > > > org.apache.commons.validator.Field.validateForRule(Field.java:808)
> > > >         at org.apache.commons.validator.Field.validate(Field.java:887)
> > > >         at org.apache.commons.validator.Form.validate(Form.java:171)
> > > >         at
> > > > org.apache.commons.validator.Validator.validate(Validator.java:367)
> > > >         at
> > > > org.apache.commons.validator.ExceptionTest.testCheckedException(Excep
> > > > tionTest.java:127)
> > > >         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > > >         at
> > > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> > > > java:39)
> > > >         at
> > > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> > > > sorImpl.java:25)
> > > >         at java.lang.reflect.Method.invoke(Method.java:324)
> > > >         at junit.framework.TestCase.runTest(TestCase.java:154)
> > > >         at junit.framework.TestCase.runBare(TestCase.java:127)
> > > >         at junit.framework.TestResult$1.protect(TestResult.java:106)
> > > >         at
> junit.framework.TestResult.runProtected(TestResult.java:124)
> > > >         at junit.framework.TestResult.run(TestResult.java:109)
> > > >         at junit.framework.TestCase.run(TestCase.java:118)
> > > >         at junit.framework.TestSuite.runTest(TestSuite.java:208)
> > > >         at junit.framework.TestSuite.run(TestSuite.java:203)
> > > >         at
> > > > org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUni
> > > > tTestRunner.java:325)
> > > >         at
> > > > org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.executeInVM(JU
> > > > nitTask.java:848)
> > > >         at
> > > > org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute(JUnitT
> > > > ask.java:556)
> > > >         at
> > > > org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute(JUnitT
> > > > ask.java:532)
> > > >         at org.apache.tools.ant.Task.perform(Task.java:341)
> > > >         at
> org.apache.commons.jelly.tags.ant.AntTag.doTag(AntTag.java:232)
> > > >         at
> org.apache.commons.jelly.impl.TagScript.run(TagScript.java:279)
> > > >         at
> > > > org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:135)
> > > >         at
> > > > org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:233)
> > > >         at
> org.apache.commons.jelly.tags.core.IfTag.doTag(IfTag.java:88)
> > > >         at
> org.apache.commons.jelly.impl.TagScript.run(TagScript.java:279)
> > > >         at
> > > > org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:135)
> > > >         at
> > > > org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:233)
> > > >         at
> > > > com.werken.werkz.jelly.GoalTag$1.performAction(GoalTag.java:128)
> > > >         at com.werken.werkz.Goal.fire(Goal.java:639)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:575)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at com.werken.werkz.Goal.attainPrecursors(Goal.java:488)
> > > >         at com.werken.werkz.Goal.attain(Goal.java:573)
> > > >         at
> > > > org.apache.maven.plugin.PluginManager.attainGoals(PluginManager.java:
> 448)
> > > >         at
> > > > org.apache.maven.MavenSession.attainGoals(MavenSession.java:348)
> > > >         at org.apache.maven.cli.App.doMain(App.java:543)
> > > >         at org.apache.maven.cli.App.main(App.java:1109)
> > > >         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > > >         at
> > > > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> > > > java:39)
> > > >         at
> > > > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> > > > sorImpl.java:25)
> > > >         at java.lang.reflect.Method.invoke(Method.java:324)
> > > >         at com.werken.forehead.Forehead.run(Forehead.java:551)
> > > >         at com.werken.forehead.Forehead.main(Forehead.java:581)
> > > >
> > > >
> > > > ---------------------------------------------------------------------
> > > > 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]
> > >
> > >
>
>
> ----------------------------------------------------------------------------
> ----
>
>
> > ---------------------------------------------------------------------
> > 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]
>
>

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

Reply via email to