@Test
    public void testAddInventoryItem() {
        final Geocache cache = new Geocache();
        assertThat(cache.getInventory()).isEmpty();
        assertThat(cache.getInventoryItems()).isEqualTo(0);

        // 1st TB
        final Trackable trackable1 = new Trackable();
        trackable1.setGeocode("TB1234");
        trackable1.setName("FOO");
        trackable1.forceSetBrand(TrackableBrand.TRAVELBUG);

        cache.addInventoryItem(trackable1);
        assertThat(cache.getInventory()).hasSize(1);
        assertThat(cache.getInventoryItems()).isEqualTo(1);
        assertThat(cache.getInventory().get(0).getGeocode()).isEqualTo("TB1234");
        assertThat(cache.getInventory().get(0).getName()).isEqualTo("FOO");
        assertThat(cache.getInventory().get(0).getDistance()).isEqualTo(-1F);
        assertThat(cache.getInventory().get(0).getOwner()).isNull();
        assertThat(cache.getInventory().get(0).getBrand()).isEqualTo(TrackableBrand.TRAVELBUG);

        // TB to be updated
        final Trackable trackable2 = new Trackable();
        trackable2.setGeocode("TB1234");
        trackable2.setName("BAR");
        trackable2.setDistance(100);
        trackable2.forceSetBrand(TrackableBrand.TRAVELBUG);
        cache.addInventoryItem(trackable2);

        assertThat(cache.getInventory()).hasSize(1);
        assertThat(cache.getInventoryItems()).isEqualTo(1);
        assertThat(cache.getInventory().get(0).getGeocode()).isEqualTo("TB1234");
        assertThat(cache.getInventory().get(0).getName()).isEqualTo("BAR");
        assertThat(cache.getInventory().get(0).getDistance()).isEqualTo(100F);
        assertThat(cache.getInventory().get(0).getOwner()).isNull();
        assertThat(cache.getInventory().get(0).getBrand()).isEqualTo(TrackableBrand.TRAVELBUG);

        // TB to be added
        final Trackable trackable3 = new Trackable();
        trackable3.setGeocode("GK6666");
        trackable3.forceSetBrand(TrackableBrand.GEOKRETY);
        cache.addInventoryItem(trackable3);

        assertThat(cache.getInventory()).hasSize(2);
        assertThat(cache.getInventoryItems()).isEqualTo(2);
        assertThat(cache.getInventory().get(0).getGeocode()).isEqualTo("TB1234");
        assertThat(cache.getInventory().get(0).getName()).isEqualTo("BAR");
        assertThat(cache.getInventory().get(0).getDistance()).isEqualTo(100F);
        assertThat(cache.getInventory().get(0).getOwner()).isNull();
        assertThat(cache.getInventory().get(0).getBrand()).isEqualTo(TrackableBrand.TRAVELBUG);

        assertThat(cache.getInventory().get(1).getGeocode()).isEqualTo("GK6666");
        assertThat(cache.getInventory().get(1).getName()).isEqualTo("");
        assertThat(cache.getInventory().get(1).getDistance()).isEqualTo(-1F);
        assertThat(cache.getInventory().get(1).getOwner()).isNull();
        assertThat(cache.getInventory().get(1).getBrand()).isEqualTo(TrackableBrand.GEOKRETY);

    }
distance circle must not be shown for waypoints of archived caches.
main/src/androidTest/java/cgeo/geocaching/models/GeocacheTest.java