Compatibility with Travis-CI #11

Closed
kaspermunck opened this Issue May 3, 2013 · 4 comments

Comments

Projects
None yet
2 participants
@kaspermunck

I am currently experienced unstable behavior when attempting to run tests from Travis-CI. xctool consistently throws the following NSInternalInconsistencyException:

Failed getting contents of directory: Error Domain=NSCocoaErrorDomain Code=260 "The folder “DiagnosticReports” doesn’t exist."
[...]

See full Travis build log and the project for which I attempt to run tests.

As a test I commented the assertion in OCUnitTestRunner.m:70 to omit the exception. This allows my tests to be run properly for now, but is probably not the way to go.

@fpotter

This comment has been minimized.

Show comment
Hide comment
@fpotter

fpotter May 3, 2013

Contributor

It's neat to see this getting used with Travis CI!

OK - this code shouldn't be barfing if the directory doesn't exist. - (void)allCrashReports should just return an empty array if the directory doesn't exist.

Want to submit a patch?

I can do it too - might not get to it today, tho.

Contributor

fpotter commented May 3, 2013

It's neat to see this getting used with Travis CI!

OK - this code shouldn't be barfing if the directory doesn't exist. - (void)allCrashReports should just return an empty array if the directory doesn't exist.

Want to submit a patch?

I can do it too - might not get to it today, tho.

@kaspermunck

This comment has been minimized.

Show comment
Hide comment
@kaspermunck

kaspermunck May 3, 2013

xctool is a bless, thank you!

I'll see if I can do it tonight, otherwise just go ahead.

xctool is a bless, thank you!

I'll see if I can do it tonight, otherwise just go ahead.

fpotter added a commit that referenced this issue May 3, 2013

don't crash if ~/Library/Logs/DiagnosticReports does not exist.
This was pretty bad - xctool would actually crash if this directory
didn't exist (meaning you had no crash reports on your system).

Fixes issue #11

Tested with...

```
./xctool.sh -workspace
xctool/xctool-tests/TestData/TestWorkspace-Library/TestWorkspace-Library.xcworkspace
-scheme TestProject-Library -configuration Debug -arch i386 -sdk
iphonesimulator test -only TestProject-LibraryTests
```
@fpotter

This comment has been minimized.

Show comment
Hide comment
@fpotter

fpotter May 3, 2013

Contributor

Hey Kasper - I think this is good to go.

Contributor

fpotter commented May 3, 2013

Hey Kasper - I think this is good to go.

@fpotter fpotter closed this May 3, 2013

@kaspermunck

This comment has been minimized.

Show comment
Hide comment
@kaspermunck

kaspermunck May 4, 2013

Awesome Fred.

Awesome Fred.

tomquist pushed a commit to tomquist/xctool that referenced this issue Aug 23, 2013

don't crash if ~/Library/Logs/DiagnosticReports does not exist.
This was pretty bad - xctool would actually crash if this directory
didn't exist (meaning you had no crash reports on your system).

Fixes issue #11

Tested with...

```
./xctool.sh -workspace
xctool/xctool-tests/TestData/TestWorkspace-Library/TestWorkspace-Library.xcworkspace
-scheme TestProject-Library -configuration Debug -arch i386 -sdk
iphonesimulator test -only TestProject-LibraryTests
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment