blob: 61ff50efa634820db64fcf6aae7a45ebcb003990 (
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
|
package org.traccar.handler.events;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import org.traccar.BaseTest;
import org.traccar.model.Position;
import org.traccar.session.cache.CacheManager;
import static org.mockito.Mockito.mock;
public class IgnitionEventHandlerTest extends BaseTest {
@Test
public void testIgnitionEventHandler() {
IgnitionEventHandler ignitionEventHandler = new IgnitionEventHandler(mock(CacheManager.class));
Position position = new Position();
position.set(Position.KEY_IGNITION, true);
position.setValid(true);
ignitionEventHandler.analyzePosition(position, Assertions::assertNull);
}
}
|