Unit testing basics in objective-c

Published 5/4/2012 8:01 PM by Toran Billups 0 Comments

Tomorrow I’m giving my first in depth objective-c talk on unit testing and I decided to produce a screencast of the content for those who can’t make the event.

I decided to keep this presentation religion free and to the point. I wanted to show unit testing in action from the very basic substring examples to parsing JSON. This along with a light introduction to the ocmock library proved to be more than enough content for a 60 minute unit testing introduction.

As always, if you want the code from this presentation you can find it on github.

Direct Download (mp4)

If you make it to the event please leave a comment with some feedback!

Tags: iphone xcode testing

Automatically activate your virtualenv

Published 4/22/2012 11:07 AM by Toran Billups 4 Comments

Since I started writing python last year I’ve spent the majority of my time developing with virtualenv. This is a great way to silo your python environment from system python so you run different versions of a dependency without having to worry about upgrading every app that’s running on your development machine / production web server / etc.

One of the annoying things about working with virtualenv on your development machine is that you need to explicitly "workon" or activate the python environment each time you open a new terminal window or change directories. This got me thinking -why not write a simple bash script that would automatically activate a virtualenv when it found one that matched the directory name.

The above can be put into your .bashrc file if you want this same auto workon behavior I was looking for. The script does assume 3 things

  • You only consider a directory that has a git repository
  • You must name the virtualenv the same as the directory that contains your project
  • You want the script to deactivate one virtualenv and workon another when you switch between different project directories

I decided to be a little more strict about when to auto workon a virtualenv because this script runs each time you execute the "cd" command. So by first making sure you had a .git file and second by making sure the name even existed as a virtualenv on your system it might save some would be wasted effort trying to activate something that wasn’t needed or didn’t exist altogether.

Tags: bash

How to export your first signed android package

Published 3/1/2012 7:24 PM by Toran Billups 0 Comments

The first time I went to publish an Android app it was unclear how to export an apk. I also thought if the app was free I wouldn’t need to do anything special to the final apk, but as it turns out you still need to sign the apk before the google market will let you upload it.

The video below is a simple walk through showing how to version/build/sign/export your apk for the google market. It’s under 5 minutes and straight to the point.

Direct Download (mp4)

If I left anything out be sure to leave a comment.

Tags: Android

Copyright © 2009 Toran Billups - Valid XHTML & CSS