aboutsummaryrefslogtreecommitdiffstats
path: root/tests/src/cgeo/geocaching/sensors/SensorsTest.java
blob: c4f70aa1584dee08a8ed1f74bd71b38a489c4fb3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package cgeo.geocaching.sensors;

import static org.assertj.core.api.Assertions.assertThat;

import cgeo.geocaching.MainActivity;

import android.test.ActivityInstrumentationTestCase2;

public class SensorsTest extends ActivityInstrumentationTestCase2<MainActivity> {

    public SensorsTest() {
        super(MainActivity.class);
    }

    @Override
    protected void setUp() throws Exception {
        super.setUp();
    }

    public static void testGetDirectionNow() {
        final float angle = DirectionProvider.getDirectionNow(1.0f);
        assertThat(angle == 1.0f || angle == 91.0f || angle == 181.0f || angle == 271.0f).isTrue();
    }

}