public async Task ReplicationConfig_MinutelyConfig_GuessSequenceNumberAt_ShouldReturnSequenceNumberContainingMinute() { Http.HttpHandler.Default = new ReplicationServerMockHttpHandler(); var replicationConfig = new ReplicationConfig("https://planet.openstreetmap.org/replication/minute/", 60); var result = await replicationConfig.GuessSequenceNumberAt(new DateTime(2019, 08, 3, 8, 15, 0)); Assert.Equal(3610524, result); }
public async Task ReplicationConfig_DailyConfig_GuessSequenceNumberAt_ShouldReturnSequenceNumberContainingDay() { Http.HttpHandler.Default = new ReplicationServerMockHttpHandler(); var replicationConfig = new ReplicationConfig("https://planet.openstreetmap.org/replication/day/", 24 * 3600); var result = await replicationConfig.GuessSequenceNumberAt(new DateTime(2019, 08, 3, 8, 15, 0)); Assert.Equal(2517, result); }