when( app.getVersion() ).thenReturn( "appVersion" );
when( client.getService( App.class ) ).thenReturn( app );
}
private void mockDevice( Client client ) {
ClientDevice device = mock( ClientDevice.class );
when( device.getLocale() ).thenReturn( Locale.CANADA );
when( device.getModel() ).thenReturn( "model" );
when( device.getOSVersion() ).thenReturn( "osVersion" );
when( device.getPlatform() ).thenReturn( Platform.ANDROID );
when( device.getVendor() ).thenReturn( "vendor" );
doReturn( Integer.valueOf( 23 ) ).when( device ).getTimezoneOffset();
doReturn( Float.valueOf( 23F ) ).when( device ).getScaleFactor();
when( client.getService( ClientDevice.class ) ).thenReturn( device );
}