Thanks for the info and sorry for the double send of that last message.  I 
wasn't sure which account one I had registered with the mailing list.  

I found the surefire reports and you are right they are not the easiest to look 
at, and in this case they are pretty cryptic [just an NPE :/]. 

I had it half right for embedding...  I had the @Embedded tag, just not the 
@Embeddable.  But after looking at more of the Hibernate documentation I see 
that what I really wanted was a One-to-One which I found an example of here:

http://www.hibernate.org/hib_docs/annotations/reference/en/html_single/#entity-overview

Thanks again,
Nathan
----- Original Message -----
From: "Matt Raible" <[EMAIL PROTECTED]>
To: [email protected]
Sent: Tuesday, September 25, 2007 10:53:12 PM (GMT-0800) America/Los_Angeles
Subject: Re: [appfuse-user] long lost developer

For an embedded POJO (like Address), you need @Component on the object
that embeds it:

    @Embedded
    public Address getAddress() {
        return address;
    }

Then you need @Embeddable on the object that's being embedded:

@Embeddable
public class Address extends BaseObject implements Serializable {

As far as failing tests - the easiest thing to do is run them in your
IDE. Otherwise, Maven stores the results in target/surefire-reports.
It's a pain to go look at a text file to figure out what's wrong, so
you can use -Dsurefire.useFile=false to get it printed to your
console.

http://appfuse.org/display/APF/Maven+2

HTH,

Matt

On 9/25/07, Nathan Anderson <[EMAIL PROTECTED]> wrote:
> Hey folks,
>
> I've been away from AppFuse a while and I'm trying to reacquaint myself but I 
> seem to be hitting some roadblocks.
>
> I have created some POJO's for my Struts 2 basic app, but I'm having a 
> problem with running my app now that I have POJO that embeds another POJO.  
> This is similar to User having an Address object, so I'm not sure why it's 
> failing.
>
> I can see that none of the Action tests are passing, but I'm having a hard 
> time finding out what the cause of the failure is.  So I guess I have 2 
> questions:
>
>   1) What's the tips and tricks for having a POJO embedded in another? [I'm 
> sure I'll be asking the same thing about Lists later ;) ]
>   2) When a test fails where can you see what the problem is?
>
> If anyone is willing to help get me rolling on this I'm also on IRC tonight 
> and for the next several nights :)
>
> Thanks,
> Nathan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
http://raibledesigns.com

---------------------------------------------------------------------
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