UI Unit Testing in Your iOS Project

When you create a new project in Xcode, you’re given the option of including two types of tests: Unit Tests and UI Tests. But I’ve often wished that these two weren’t mutually exclusive.

There have been times when I’ve wanted to test UI components in isolation, but I wasn’t sure how feasible it was, or if it even made sense. A similar concept exists in some web frameworks (e.g. component integration tests in Ember or React), but I wanted to try it out in iOS. Read more on UI Unit Testing in Your iOS Project…

Azure Functions in F# (For Real)

If you’ve ever glanced at Azure Functions and F#, you might think they were made for each other. And yet if you want to create a new Azure Function project in Visual Studio, C# is apparently your only option.

Maybe someday, Visual Studio will include support for Azure Functions in F#, but for now it’s possible to get there by adapting the C# Azure Function template. After all, F# is a first-class language on the .NET CLR, and it’s all the same once it’s compiled anyway. Read more on Azure Functions in F# (For Real)…

Using Fuzzy-Find to Enhance Git Add

A frequent part of my daily workflow involves adding files to Git. Since I like to keep commits relatively small and focused, that often means adding only a subset of changed files in my working tree. With the git command-line client, that is usually accomplished by copying and pasting the files I want from the git status output. A small annoyance perhaps, but since it’s something I do quite often, I have been looking for a way to improve it. Read more on Using Fuzzy-Find to Enhance Git Add…

The Five Habits of Maintainable Unit Tests

I like unit tests. They’re often the best documentation of a project’s behavior. They provide assurance that code modifications haven’t broken anything.

But too many or poorly-written tests can have the undesirable effect of cementing code in place, making it more difficult to change. The following are some practical things I keep in mind when writing unit tests. Read more on The Five Habits of Maintainable Unit Tests…

Android ConstraintLayout vs. iOS AutoLayout

Having worked on an app with both native iOS and Android versions, it’s been interesting to compare and contrast the layout approaches of both platforms. iOS has had a constraint-based layout system for quite some time now in the form of AutoLayout, while Android has only recently added a similar system called ConstraintLayout. Read more on Android ConstraintLayout vs. iOS AutoLayout…

Six Strategies to Spend Less Time Debugging

Debugging is a drag. I think we can all agree that working on new code is generally more fun and interesting than debugging or maintaining existing code. But the fact is that much of our time is spent doing the latter. When estimating time required a project or feature, it is practically impossible to predict the time required for debugging. Read more on Six Strategies to Spend Less Time Debugging…

Centralize Callback Handling by Creating a Reactive Signal

When I first started using ReactiveCocoa (now ReactiveObjC), I mainly stuck to the basic operators: map, flatten, merge, etc. I saw a few examples of createSignal, but all I saw was a lot of manual work with disposables, subscribers, and other tedious sorts of things that I didn’t really want to mess with. Read more on Centralize Callback Handling by Creating a Reactive Signal…

Three Strategies for Maintaining an App on Two Platforms

If you want mobile apps for both Android and iOS, the cross-platform framework approach sounds pretty great, promising that you only have to develop the app once to run on multiple target platforms. Developing two separate apps sounds as if it will require fully twice as much work. Read more on Three Strategies for Maintaining an App on Two Platforms…