public void GetCinemas_ThrowsWhenLimitSmallerOrEqual0()
        {
            IKinoheldApiClient client = new KinoheldApiClient();

            Assert.ThrowsAsync <ArgumentOutOfRangeException>(async() =>
            {
                var o = await client.GetCinemas("aurich", null, 1, 0, GetCinemasDynamicQuery.Full, CancellationToken.None);
            });
            Assert.ThrowsAsync <ArgumentOutOfRangeException>(async() =>
            {
                var o = await client.GetCinemas("aurich", null, 1, -1, GetCinemasDynamicQuery.Full, CancellationToken.None);
            });
        }
        public void GetCinemas_ThrowsWhenCityNotFilled()
        {
            IKinoheldApiClient client = new KinoheldApiClient();

            Assert.ThrowsAsync <ArgumentNullException>(async() =>
            {
                var o = await client.GetCinemas(null, null, 15, 5, GetCinemasDynamicQuery.Full, CancellationToken.None);
            });
            Assert.ThrowsAsync <ArgumentNullException>(async() =>
            {
                var o = await client.GetCinemas(string.Empty, null, 15, 5, GetCinemasDynamicQuery.Full, CancellationToken.None);
            });
        }
        public void GetCinemas_ThrowsOnCancel()
        {
            CancellationTokenSource cts = new CancellationTokenSource();
            cts.Cancel();

            IKinoheldApiClient client = new KinoheldApiClient();
            Assert.ThrowsAsync<TaskCanceledException>(async () =>
            {
                var o = await client.GetCinemas("aurich", null, 10, 5, GetCinemasDynamicQuery.Full, cts.Token);
            });
        }
 public async Task GetCinemas_ReturnsSomeCinemas()
 {
     IKinoheldApiClient client = new KinoheldApiClient();
     var cinemas = await client.GetCinemas("aurich", string.Empty, 15, 5, GetCinemasDynamicQuery.Full, CancellationToken.None);
     Assert.IsNotNull(cinemas);
 }