@Test
public void build() throws Exception {

    final Distance distance = new DistanceBuilderFactory(ID)
            .setUuid(DIST_UUID)
            .setTrip(mTrip)
            .setLocation(LOCATION)
            .setDistance(DISTANCE)
            .setDate(DATE)
            .setTimezone(TIMEZONE)
            .setRate(RATE)
            .setCurrency(CURRENCY_CODE)
            .setComment(COMMENT)
            .setSyncState(mGetSyncState)
            .setPaymentMethod(PAYMENT_METHOD)
            .setLocationHiddenFromAutoComplete(LOCATION_HIDDEN_FROM_AUTO_COMPLETE)
            .setCommentHiddenFromAutoComplete(COMMENT_HIDDEN_FROM_AUTO_COMPLETE)
            .build();
    assertEquals(distance, mDistanceDatabaseAdapter.build(mDistance, ID, DIST_UUID, mock(DatabaseOperationMetadata.class)));
    assertEquals(distance.getSyncState(), mDistanceDatabaseAdapter.build(mDistance, ID, DIST_UUID, mock(DatabaseOperationMetadata.class)).getSyncState());
}