Skip to main content

Android dev

Posts about Android development

The cover of "Detox and React Native: UI testing Android permission flows"

Detox and React Native: UI testing Android permission flows

I’m currently learning React Native and Expo as an alternative to native app development. To do this, I’ve been working on an app so that I can get hands-on experience with React Native app development. This includes end-to-end UI testing, using Detox.

I was surprised that Detox doesn’t have an API to interact with permissions. The device.launchApp function does have a permissions field, but this only works on iOS and runs on app start-up - it doesn’t allow you to test the actual user flow.

In this article, I will explain how you can do end-to-end testing with Android permissions, including simulating user interaction with the Android permission request modal.

Read more of "Detox and React Native: UI testing Android permission flows"

The cover of "Thoughts on native Android development"

Thoughts on native Android development

I love making apps. I like making stuff and it’s even better when I can interact with the stuff I make. App development feels especially real as I can hold and touch what I made. So why don’t I have many Android hobby projects? This article is a reflection on the projects I’ve worked on, the problems I have, and what I want to try in the future.

Read more of "Thoughts on native Android development"

The cover of "Minetest Mods: my first Android app"

Minetest Mods: my first Android app

In 2016, I created an app to install mods for Minetest’s Android port. It was my first Android app; it taught me a great deal about Android development and also helped me get my first programming job.

Minetest is an open-source game engine with millions of downloads and thousands of weekly players. The project has a very active modding community, with many games available to play. Before I created the app, users had to manually install content by unzipping their files into a directory; this was a poor user experience, especially on Android, so I created the app to make this easier.

Minetest now has ContentDB, a platform I created to browse and install mods and games within Minetest. Because of this, the app is now obsolete and is no longer available for download. That doesn’t mean this app is fully gone - the lessons I learned live on in ContentDB.

Read more of "Minetest Mods: my first Android app"

The cover of "ForumMate: My return to Android app development"

ForumMate: My return to Android app development

I worked as an Android developer just over two years ago, creating native apps for clients using Java and Kotlin. During that time, Kotlin was gaining prominence and had just been made official by Google. Google also introduced Architecture Components that year, later renamed to JetPack. Since then, the Android ecosystem has changed significantly, with Kotlin and JetPack gaining significant maturity and development. Out with Realm, Activities, and Model-View-Presenter (MVP), in with Room, fragment-based architecture, and MVVM. Data-binding and MVVM are pretty awesome and breathe a whole new life into Android app development.

Read more of "ForumMate: My return to Android app development"

Android: Complete, generic data-binding RecyclerView adapter

Data binding greatly reduces the amount of code you need to connect user-interfaces with ViewModels. It keeps Activity and Fragment code small, and makes it easier to manage lifecycles.


I discovered that there was no attribute to bind the elements in a RecyclerView, due to the fact that a RecyclerView needs an adapter to be able to create element views. It would also be nice to automatically use data binding to create the viewholders. There are a number of guides to do both of these halves, but I now present the code to do the whole.

Read more of "Android: Complete, generic data-binding RecyclerView adapter"