Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Unit testing on iPhone fails
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  Messages 1 - 25 of 30 - Collapse all  -  Translate all to Translated (View all originals)   Newer >
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Vladimir Pouzanov  
View profile  
 More options Mar 27 2010, 10:08 am
From: Vladimir Pouzanov <farcal...@gmail.com>
Date: Sat, 27 Mar 2010 07:08:21 -0700 (PDT)
Local: Sat, Mar 27 2010 10:08 am
Subject: Unit testing on iPhone fails
Hello,

I'm using beta4 sdk and try to debug an iPhone project. While running
the tests I get a message:

Tests[1334:4303] SBSetAccelerometerClientEventsEnabled failed: (ipc/
send) invalid destination port

After which the script seem to be frozen, until I kill it. Any hints?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Thomas Van Lenten  
View profile  
 More options Mar 27 2010, 11:24 am
From: Thomas Van Lenten <thoma...@gmail.com>
Date: Sat, 27 Mar 2010 11:24:07 -0400
Local: Sat, Mar 27 2010 11:24 am
Subject: Re: Unit testing on iPhone fails

Without more info, it's sorta hard to tell, that's something from your code,
so what happens after/around that is up in the air.  I'd suggest putting the
test under the debugger, to see what happens and where you're really getting
stuck.

TVL

On Sat, Mar 27, 2010 at 10:08 AM, Vladimir Pouzanov <farcal...@gmail.com>wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Vladimir Pouzanov  
View profile  
 More options Mar 27 2010, 3:52 pm
From: Vladimir Pouzanov <farcal...@gmail.com>
Date: Sat, 27 Mar 2010 12:52:48 -0700 (PDT)
Local: Sat, Mar 27 2010 3:52 pm
Subject: Re: Unit testing on iPhone fails
On Mar 27, 5:24 pm, Thomas Van Lenten <thoma...@gmail.com> wrote:

> Without more info, it's sorta hard to tell, that's something from your code,
> so what happens after/around that is up in the air.  I'd suggest putting the
> test under the debugger, to see what happens and where you're really getting
> stuck.

It's somewhat hard to set all the required environment variables to
run the app's binary directly from shell, so I can be sure only about
the following steps:
1. Shell script runs
"$TARGET_BUILD_DIR/$EXECUTABLE_PATH" -RegisterForSystemEvents
Starting the actual application binary.

2. Application makes some activity:
Tests(6354) malloc: protecting edges
Tests(6354) malloc: recording malloc stacks to disk using standard
recorder
Tests(6354) malloc: enabling scribbling to detect mods to free blocks
Tests(6354) malloc: stack logs being written into /tmp/stack-logs.
6354.Tests.msbKrs.index
objc[6354]: REPLACED: -[NSSet initWithCoder:]  by category NSSet  (IMP
was 0x1c4a950 (/Developer/Platforms/iPhoneSimulator.platform/Developer/
SDKs/iPhoneSimulator3.1.3.sdk/System/Library/Frameworks/
CoreFoundation.framework/CoreFoundation), now 0x20e50 (/Developer/
Platforms/iPhoneSimulator.platform/Developer/SDKs/
iPhoneSimulator3.1.3.sdk/System/Library/Frameworks/
Foundation.framework/Foundation))
...
objc[6354]: REPLACED: -[NSString drawInRect:withFont:]  by category
UIStringDrawing  (IMP was 0x44baf4 (/Developer/Platforms/
iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator3.1.3.sdk/
System/Library/Frameworks/UIKit.framework/UIKit), now 0x2abbae (/
Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/
iPhoneSimulator3.1.3.sdk/System/Library/Frameworks/UIKit.framework/
UIKit))
2010-03-27 21:47:38.337 Tests[6354:4303]
SBSetAccelerometerClientEventsEnabled failed: (ipc/send) invalid
destination port

After that is sits in run loop forever.

I have an older iPhone project that uses GTM for its unit testing.
Tests run flawlessly there. They fail only on newly created projects.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Thomas Van Lenten  
View profile  
 More options Apr 6 2010, 2:16 pm
From: Thomas Van Lenten <thoma...@gmail.com>
Date: Tue, 6 Apr 2010 14:16:47 -0400
Local: Tues, Apr 6 2010 2:16 pm
Subject: Re: Unit testing on iPhone fails

Nothing is jumping out at me there, if you've got some that work and some
that don't, I'd suggest comparing them for config difference and/or the
differences in what of your own code your pulling in, bisection that might
help you figure out what's triggering it.  Otherwise, putting things under a
debugger might also shed some light.

TVL

On Sat, Mar 27, 2010 at 3:52 PM, Vladimir Pouzanov <farcal...@gmail.com>wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
vincent daubry  
View profile  
 More options Apr 13 2010, 5:59 am
From: vincent daubry <vdau...@gmail.com>
Date: Tue, 13 Apr 2010 02:59:17 -0700 (PDT)
Local: Tues, Apr 13 2010 5:59 am
Subject: Re: Unit testing on iPhone fails
I have exactly the same problem. I solved it by removing the
mainWindow from the test target.
This is weird...

On 6 avr, 20:16, Thomas Van Lenten <thoma...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
vincent daubry  
View profile  
 More options Apr 13 2010, 5:59 am
From: vincent daubry <vdau...@gmail.com>
Date: Tue, 13 Apr 2010 02:59:53 -0700 (PDT)
Local: Tues, Apr 13 2010 5:59 am
Subject: Re: Unit testing on iPhone fails
MainWidow.xib i meant

On 13 avr, 11:59, vincent daubry <vdau...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Dave MacLachlan  
View profile  
 More options Apr 13 2010, 12:39 pm
From: Dave MacLachlan <dmacl...@gmail.com>
Date: Tue, 13 Apr 2010 09:39:23 -0700
Local: Tues, Apr 13 2010 12:39 pm
Subject: Re: Unit testing on iPhone fails
Can you hook a debugger up to it? Does the  
applicationDidFinishLaunching: in GTMIPhoneUnitTestDelegate ever get  
called?

Cheers,
Dave

On Apr 13, 2010, at 02:59 , vincent daubry wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
vincent daubry  
View profile  
 More options Apr 19 2010, 12:02 pm
From: vincent daubry <vdau...@gmail.com>
Date: Mon, 19 Apr 2010 09:02:51 -0700 (PDT)
Local: Mon, Apr 19 2010 12:02 pm
Subject: Re: Unit testing on iPhone fails
Hi,

Sorry for answering so late.
I'm not sure to understand what you mean : the run script build phase
never ends so i cannot use xcode debugger (it only stop on breakpoint
at runtime, not at compile time, or am i missing something ?)

Should i use some external debugger ?

Thanks,
Vincent.

On 13 avr, 18:39, Dave MacLachlan <dmacl...@gmail.com> wrote:

--
You received this message because you are subscribed to the Google Groups "google-toolbox-for-mac" group.
To post to this group, send email to google-toolbox-for-mac@googlegroups.com.
To unsubscribe from this group, send email to google-toolbox-for-mac+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-toolbox-for-mac?hl=en.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Dave MacLachlan  
View profile  
 More options Apr 19 2010, 12:21 pm
From: Dave MacLachlan <dmacl...@gmail.com>
Date: Mon, 19 Apr 2010 09:21:38 -0700
Local: Mon, Apr 19 2010 12:21 pm
Subject: Re: Unit testing on iPhone fails
Once the script is being run your project has actually been built. You  
should be able to set up a custom executable and debug it.

BTW if you have trouble setting up a custom executable, can I  
recommend installing the GTM Xcode plugin from here:

http://code.google.com/p/google-toolbox-for-mac/downloads/list

It gives you a menu option for creating custom executables which you  
could then use to debug your problem.

Limited docs are here:
http://code.google.com/p/google-toolbox-for-mac/wiki/GTMXcodePlugin

Cheers,
Dave

On Apr 19, 2010, at 09:02 , vincent daubry wrote:

--
You received this message because you are subscribed to the Google Groups "google-toolbox-for-mac" group.
To post to this group, send email to google-toolbox-for-mac@googlegroups.com.
To unsubscribe from this group, send email to google-toolbox-for-mac+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-toolbox-for-mac?hl=en.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Meredith  
View profile  
 More options May 31 2010, 2:29 pm
From: Meredith <bitcab...@gmail.com>
Date: Mon, 31 May 2010 11:29:26 -0700 (PDT)
Local: Mon, May 31 2010 2:29 pm
Subject: Re: Unit testing on iPhone fails
The relevant line is:

UnitTest[44140:903] SBSetAccelerometerClientEventsEnabled failed: (ipc/
send) invalid destination port

So the problem has something to do with how the plugin is handling the
Accelerometer, probably related to GTMObjC2Runtime.

On Apr 19, 12:21 pm, Dave MacLachlan <dmacl...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Thomas Van Lenten  
View profile  
 More options May 31 2010, 6:50 pm
From: Thomas Van Lenten <thoma...@gmail.com>
Date: Mon, 31 May 2010 18:50:49 -0400
Local: Mon, May 31 2010 6:50 pm
Subject: Re: Unit testing on iPhone fails

On Mon, May 31, 2010 at 2:29 PM, Meredith <bitcab...@gmail.com> wrote:
> The relevant line is:

> UnitTest[44140:903] SBSetAccelerometerClientEventsEnabled failed: (ipc/
> send) invalid destination port

> So the problem has something to do with how the plugin is handling the
> Accelerometer, probably related to GTMObjC2Runtime.

The file basically compiles away on the iPhone into nothing.

Do you already have a copy of the Simulator running when you are trying to
run the unit tests?

TVL


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin DeWind  
View profile  
 More options Jun 30 2010, 8:34 am
From: Justin DeWind <dewi...@gmail.com>
Date: Wed, 30 Jun 2010 05:34:24 -0700 (PDT)
Local: Wed, Jun 30 2010 8:34 am
Subject: Re: Unit testing on iPhone fails
I am also having this exact same problem when attempting to run tests
against the iOS4 SDK. The tests were running fine previous to the
upgrade

On May 31, 6:50 pm, Thomas Van Lenten <thoma...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Thomas Van Lenten  
View profile  
 More options Jun 30 2010, 10:07 am
From: Thomas Van Lenten <thoma...@gmail.com>
Date: Wed, 30 Jun 2010 10:07:28 -0400
Local: Wed, Jun 30 2010 10:07 am
Subject: Re: Unit testing on iPhone fails

Is the simulator still running?

TVL


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin DeWind  
View profile  
 More options Jun 30 2010, 10:11 am
From: Justin DeWind <dewi...@gmail.com>
Date: Wed, 30 Jun 2010 10:11:05 -0400
Local: Wed, Jun 30 2010 10:11 am
Subject: Re: Unit testing on iPhone fails

No, it is not. I declared open war on all processes that could even remotely
be associated with the simulator; including the simulator itself. I also
made sure to reboot in order to clear any potential zombie processes that I
could not find.

Is it possible that the socket/ipc communication has changed in the new
simulator?

Justin DeWind

On Wed, Jun 30, 2010 at 10:07 AM, Thomas Van Lenten <thoma...@gmail.com>wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Thomas Van Lenten  
View profile  
 More options Jun 30 2010, 12:23 pm
From: Thomas Van Lenten <thoma...@gmail.com>
Date: Wed, 30 Jun 2010 12:23:56 -0400
Local: Wed, Jun 30 2010 12:23 pm
Subject: Re: Unit testing on iPhone fails

On Wed, Jun 30, 2010 at 10:11 AM, Justin DeWind <dewi...@gmail.com> wrote:
> No, it is not. I declared open war on all processes that could even
> remotely be associated with the simulator; including the simulator itself. I
> also made sure to reboot in order to clear any potential zombie processes
> that I could not find.

> Is it possible that the socket/ipc communication has changed in the new
> simulator?

Almost possible, I don't think Dave or I have had enough cycles to poke
around and specific things like that.

TVL

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin DeWind  
View profile  
 More options Jun 30 2010, 2:16 pm
From: Justin DeWind <dewi...@gmail.com>
Date: Wed, 30 Jun 2010 14:16:03 -0400
Local: Wed, Jun 30 2010 2:16 pm
Subject: Re: Unit testing on iPhone fails

Yikes,

Well, I'll have to spend sometime drilling down into the codebase in order
to determine why this might be happening.

Justin DeWind

On Wed, Jun 30, 2010 at 12:23 PM, Thomas Van Lenten <thoma...@gmail.com>wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Dave MacLachlan  
View profile  
 More options Jun 30 2010, 5:44 pm
From: Dave MacLachlan <dmacl...@gmail.com>
Date: Wed, 30 Jun 2010 14:44:17 -0700
Local: Wed, Jun 30 2010 5:44 pm
Subject: Re: Unit testing on iPhone fails

Justin, can you send me some sample code that shows a failure that I  
can play with?

Cheers,
Dave

On Jun 30, 2010, at 11:16 , Justin DeWind wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin DeWind  
View profile  
 More options Jun 30 2010, 6:12 pm
From: Justin DeWind <dewi...@gmail.com>
Date: Wed, 30 Jun 2010 18:12:19 -0400
Local: Wed, Jun 30 2010 6:12 pm
Subject: Re: Unit testing on iPhone fails

Yes,

I will put together a project that reflects the structure of the ones I am working on.

Sent from my iPhone

On Jun 30, 2010, at 5:44 PM, Dave MacLachlan <dmacl...@gmail.com> wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin DeWind  
View profile  
 More options Jul 1 2010, 11:04 am
From: Justin DeWind <dewi...@gmail.com>
Date: Thu, 1 Jul 2010 11:04:59 -0400
Local: Thurs, Jul 1 2010 11:04 am
Subject: Re: Unit testing on iPhone fails

Alright,

I have created a project that exhibits the same symptoms that my other iOS4
projects have. The tests run infinitely because the application run loop
never terminates and the test application is never launched (headless). It
look as if it it could be a spring board socket communication issue that
prevents the script from every properly invoking the tests?

A a couple of things to note:

   - This project depends on two static libraries -- OCMock and OCHamcrest
      - OCMock and OCHamcrest cannot be linked against anymore in iOS4 --
      yay
      - The project has direct dependencies on the project
      - It links in the static libraries via the library and header search
      paths under the build preferences for that target
   - I was forced into include all of my XIB resources
      - I was getting exceptions because certain iOS 4 (UINib) were
      explicitly looking for MainWindow and related dependencies
within that XIB
      file

The git repo is located at http://github.com/dewind/iOS4GoogleToolbox and
you can clone it at g...@github.com:dewind/iOS4GoogleToolbox.git

Justin DeWind

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin DeWind  
View profile   Translate to Translated (View Original)
 More options Jul 1 2010, 11:08 am
From: Justin DeWind <dewi...@gmail.com>
Date: Thu, 1 Jul 2010 11:08:33 -0400
Local: Thurs, Jul 1 2010 11:08 am
Subject: Re: Unit testing on iPhone fails

I should amend my first paragraph. The test application is "launched", but
the tests never run.

Justin DeWind

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Dave MacLachlan  
View profile  
 More options Jul 1 2010, 12:53 pm
From: Dave MacLachlan <dmacl...@gmail.com>
Date: Thu, 1 Jul 2010 09:53:22 -0700
Local: Thurs, Jul 1 2010 12:53 pm
Subject: Re: Unit testing on iPhone fails

The tests aren't running because of a problem with the delegate.  
Unfortunately this is a very easy mistake to make.

We need GTMIPhoneUnitTestDelegate to be the application delegate. We  
were doing this by starting up with UIApplicationMain(argc, argv, nil,  
@"GTMIPhoneUnitTestDelegate") in GTMIPhoneUnitTestMain. Your app  
starts up fine, but when it loads MainWindow.xib it reassigns the app  
delegate from GTMiPhoneUnitTestDelegate to your  
iOS4GoogleToolboxAppDelegate. Therefore our delegate never gets the  
applicationDidFinishLaunching: notification.

I'm not sure if this behavior changed in iOS4 or has always been  
there, but I've got a fix I can think of, so I'll try and put  
something together for you. Assuming my partner in crime thinks it's  
worthwhile, I should have it posted today.

Thanks for the project.

Cheers,
Dave

On Jul 1, 2010, at 08:08 , Justin DeWind wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin DeWind  
View profile  
 More options Jul 1 2010, 12:56 pm
From: Justin DeWind <dewi...@gmail.com>
Date: Thu, 1 Jul 2010 12:56:23 -0400
Local: Thurs, Jul 1 2010 12:56 pm
Subject: Re: Unit testing on iPhone fails

That makes complete sense. It seems that the errors led me down a path that
hosed the test target. The fact that I was forced to include XIB files --
which I am not happy with.

Justin DeWind

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Dave MacLachlan  
View profile  
 More options Jul 1 2010, 1:46 pm
From: Dave MacLachlan <dmacl...@gmail.com>
Date: Thu, 1 Jul 2010 10:46:36 -0700
Local: Thurs, Jul 1 2010 1:46 pm
Subject: Re: Unit testing on iPhone fails

Fix for you is in the TOT for GTM. While I was playing I figured out a  
solution to another iOS4 issue that's been plaguing me, and a work  
around for it should be in soon... around 1100 AM PST.

Problem is detailed here:

http://openradar.appspot.com/8081169

Cheers,
Dave

On Jul 1, 2010, at 09:56 , Justin DeWind wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin DeWind  
View profile  
 More options Jul 1 2010, 1:50 pm
From: Justin DeWind <dewi...@gmail.com>
Date: Thu, 1 Jul 2010 13:50:10 -0400
Local: Thurs, Jul 1 2010 1:50 pm
Subject: Re: Unit testing on iPhone fails

Dave,

Thanks, the tests now run. However, and maybe this is related to the other
issue you are addressing. It looks like any failure exceptions are not being
caught by the code that is executing tests. But instead, it is bubbling to
the top and causing the application to quit with an exception. Which means
that once a test fails the rest will not run.

Justin DeWind

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Dave MacLachlan  
View profile  
 More options Jul 1 2010, 3:27 pm
From: Dave MacLachlan <dmacl...@gmail.com>
Date: Thu, 1 Jul 2010 12:27:10 -0700
Local: Thurs, Jul 1 2010 3:27 pm
Subject: Re: Unit testing on iPhone fails

That would be the issue that is now fixed in TOT.

Cheers,
Dave

On Jul 1, 2010, at 10:50 , Justin DeWind wrote:

...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Messages 1 - 25 of 30   Newer >
« Back to Discussions « Newer topic     Older topic »