Running Android unit / instrumentation tests from the console

Unit tests

Here’s a few handy commands if you want to run only a specific unit test(s). Suppose we have the following unit tests in the project:
unit_tests

./gradlew test – run unit tests for all variants
./gradlew testDebug – run tests for Debug variant
./gradlew testDebug --tests="*.helpers.*" – run all tests in the helpers package
./gradlew testDebug --tests="*.HelperTest" – run all tests in HelperTest.java class
./gradlew testDebug --tests="*.getHelp" – run only the getHelp test method.
read more

60 day running challenge

Today I took up a 60 day running challenge. It’s super simple – I need to run 60 consecutive days to succeed. I took up the challenge mainly for 2 reasons:

  • To give myself a lesson in persistence, which I truly believe is the most important factor to success in any field or undertaking.
  • Health benefits – I don’t expect to become a model, but should see some (minor) weight loss and boost in my overall energy levels and endurance.
  • Fun – experienced runners say running can be fun. Currently I don’t see how this can be true, but let’s put it to the test.

Well today I did get to Primrose Hill and backwards, so let’s say run 00 to be completed.
run00

Level-up your Android development by using a proxy tool

This post will list some of my favourite features of a Proxy tool that are used on a daily bases in my team. It’s about giving you the overview of how such a tool will help you be more efficient in your day-to-day development process. It won’t get into details of how to setup a proxy, how to use these features or which specific tool to use – this will be covered in a future post.

Let’s get to it!
read more

Percent Support Library – what, when, how?

What, when?

With the release of Android M (API 23) the Support library got a major update as well. One of the unsung heroes is a feature badly requested since Android’s early days – the ability to set dimensions in percentages. With the release of the Percent Support Library is’t now possible to set a View to take exactly 30% of the screen, or to set it’s marginTop to 10% for example.

read more

Basic Java: What Interfaces really are?

As an assistant of a course in basic Java in my local university, I saw a common misunderstanding among students what interfaces really are. In this short article I’ll try to give students another point of view.

As we all know “an interface is a group of related methods with empty bodies”*. Consider the following example:
read more