So, the Android M Developer Preview is out! All related info is already published, including the Program Overview, guide to Setting up the SDK and the collection of Samples illustrating brand new Android features.
First, make sure you've installed all necessary stuff to run Android M Developer Preview, and created an emulator with the newest Android version. Clone the repo, import the app into the Android Studio and run it. Here's what we see:
To try the authentication, first we'll need to enroll a fingerprint. Navigate to Settings > Security > Fingerprint and follow the instructions to add one. Apparently, you'll need to set up either a PIN, a Pattern or a Password for the device in order to register a fingerprint. When done, you'll be presented with the following screen:
Tapping on the monitor probably won't get you far, so instead open the Terminal and use the following command to emulate the touch:
adb -e emu finger touch 1
'1' here identifies the fingerprint, so just use any random number value. The fingerprint should be added successfully and you'll see the confirmation screen:
So far so good! Now let's head back to the sample app. The "Purchase" button is now available, so let's try to make a fingerprint-authenticated purchase:
Tap on "Purchase" and you'll be presented with the authentication dialog:
Open the Terminal again and type the same command used previously to register the fingerprint. The dialog will disappear - authentication successful!
Fingerprint Authentication promises to be a pretty interesting feature in the coming Android M release, but there's lots of other exciting stuff under the Android M Developer Preview. Keep exploring!