Sometimes OS X Software Update might think it has downloaded and installed the update, especially for pre-Mac App Store applications such as the iLife programs. The way to resolve this is to go to Apple Support Downloads and download the individual update. You can also get the OS X Combo Updaters this way.
I tried to use the command line Subversion application svn
in my recently updated installation of OS X 10.8 Mountain Lion. Couldn’t find the command at all. Hmm… used to be pre-installed in Lion and previous versions. Looked around the interwebs and found this reference: Where is SVN on OS X Mountain Lion?. You have to install Xcode from the App Store and then download the command line utilities. svn
will get installed in /usr/bin
and thus appears in the default PATH
.
One of the nice things in Xcode 4 is the integration of the OCUnit, or SenTestKit, Unit Test suite into the environment. My last foray into unit testing was with JUnit in Eclipse. I’m currently working on an Objective-C library using JSON for data transmission and needed to test its methods.
Here’s a good guide on setting up a project to use OCUnit and OCMock for mock objects – Unit Testing in Xcode 4 Quick Start Guide | Ray Wenderlich. The article also mentions GHUnit which has some additional features over OCUnit – will have to look at that too!
So I’ve written my test cases and run them. I then see several test failures which seemed out of the ordinary. Now, the test cases are written in the order I expect them to run in the file, and I noticed that they were being run in an order other than the sequence in the file, which is what I was used to in JUnit. The Unit Test documentation on the Apple developer site Xcode Unit Testing Guide doesn’t mention anything about the order of test case execution, and I could not find anything relevant on the ‘net.
After scrutinising the test case run order, I came to the conclusion that it was in alphabetical order! And now I’ve taken to numbering the test cases thusly – test_0010_xxx and so forth – shades of BASIC line numbers!
And there’s more – unit tests are by their intent, tests for a unit. Each is a single entity which performs a set of operations as an independent standalone code segment. I had instead written test methods which were dependent on the previous method’s results – not a real unit test at all, and therefore a new lesson learnt! In fact, Apple documentation states: “When Xcode runs unit tests, it invokes each test case method independently.” Might not need those line numbers after all…
So chalk this one up to experience, and blog it for all to find out!
Waiting for Keith Dahlby’s talk to start on GitHub at Iowa Code Camp.
I’m presenting at the Iowa Code Camp Spring 2012 event. This year I’m speaking on Design Patterns – as it’s my belief that software developers who understand the essential principles of their art will transcend languages, libraries, and development environments.
PDF of the slides are here. Enjoy!
I found this neat technique to upload Markdown from MarsEdit to a WordPress site and have it automagically format the MarkDown as HTML. Here’s the link to Cek’s blog. You’ll need Markdown on Save Improved installed as a WordPress plugin. Activate it and vóila – you have that magical Markdown conversion – direct from MarsEdit. Enjoy!
The second item I reviewed for Allison Sheridan’s NosillaCast podcast is the CableJive dockStubz Charge Converter and 30-pin Pass Through Adapter. Here are the problems to be solved…
You’ve got an iPhone safely wrapped up in a case and you like to plug it into a video output adapter. But wait, the connector is just slightly larger then the standard dock connector. You sigh loudly as you remove the case for the umpteenth time to plug in the video connector.
Or perhaps you have a dock connector in your car. It used to charge your old iPod but does not charge your brand new iPhone 4S at all. That’s because the iPhone now uses USB versus FireWire. You can play music but your iPhone will be discharging.
Here’s a third common issue – you have an iPad and want to use the VGA adapter but your battery is low. There’s no time to recharge before the important presentation.
Three problems – one solution. The CableJive dockStubz – it’s three things in one: a pass through dock connector, a charge converter, and an external charge adapter.
In the first scenario, you plug the oversized dock connector into the socket at one end of the dockStubz and plug the dockStubz’s standard size dock connector into your encased iPhone. It fits all cases as it is exactly the same size as the standard Apple dock connector. You can even plug it into the connector in Apple’s iPod dock and plug your iPhone into that.
For the second situation, the dockStubz contains circuitry to convert the FireWire power voltage to USB levels. You simply plug the dockStubz into the automotive dock connector and the iPhone into the dockStubz. It’s really that easy.
And in the case of the last scenario, the dockStubz has a micro-B USB receptacle on the side through which you can supply additional power. Since the Apple VGA adapter does not come with a dock connector power socket, as in the HDMI adapter, the dockStubz comes in handy to power your iPad while using the VGA adapter.
The dockStubz is available from Amazon and other retailers. It costs just a little more than $20. You’ll find that it’s such a handy little device to keep in your bag of device adapters. One thing I found amiss was that CableJive could have included a USB-A to Micro-B connector but alas, that was not the case. Fortunately my travel kit bag is equipped with that cable so I’m all set.
Link at CableJive’s website
Link at Amazon
Link to the NosillaCast #364 review
I did a couple of reviews for Allison Sheridan’s NosillaCast at podfeet.com. The first item is the iLuv Inline Remote, also known as the iPod Remote with Third-party Headphones Adapter for VoiceOver.
Ever been in this situation before? You’re listening to a podcast on your iOS device through speakers connected to your headphone jack and you need to pause it. You hit the home button twice and then tap on the pause button on the display. Wouldn’t it be nice if your speakers came with the same remote as on the iPhone headphones?
So here’s the solution to that problem – the iLuv inline remote. This is a simple little device which has an iPhone four conductor 1/8″ plug on one end and a 1/8″ jack on the other. In the middle there’s a three button remote similar to that on the iPod Shuffle (the one without the buttons). The buttons control the volume and provide play / pause functionality. Double clicking on the centre play / pause button skips to the next track, triple clicking skips to the previous track, much like the Apple inline remote.
You plug your regular speakers or headset into the jack and then plug in the iLuv into the iDevice. And voila! You have a remote control!
The iLuv remote is available in either black or white. You can get it for under $10 from Amazon, I’d recommend you use Allison’s link on her web page.
Advantages: it’s short in length, about 6 inches, and does not appreciably extend the length of the speaker cable. It also works with any speaker – powered or non powered – or headset. My one issue is that it doesn’t have a microphone, but for that price, I’m more than happy.
The iLuv remote sits quietly in between your iDevice and audio outputs and lets you control volume and play or pause the audio. Now I don’t have to turn on the iPhone just to pause a podcast.
Link on iLuv’s website
Link on Amazon
And here’s the review on NosillaCast #364
Just migrated the blog to WordPress so I can make entries from iOS devices as well as from the Mac. Major site edits will still occur in RapidWeaver. Thanks to the WP-Blog plugin from nilrog’s place