mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-16 10:03:51 -07:00
Updated restmodule, moved series, root folder to the new restmodule.
This commit is contained in:
parent
4878556e14
commit
a2e84a8f83
16 changed files with 321 additions and 219 deletions
44
NzbDrone.Integration.Test/SeriesIntegrationTest.cs
Normal file
44
NzbDrone.Integration.Test/SeriesIntegrationTest.cs
Normal file
|
@ -0,0 +1,44 @@
|
|||
using System.Net;
|
||||
using FluentAssertions;
|
||||
using NUnit.Framework;
|
||||
using NzbDrone.Api.Series;
|
||||
using System.Linq;
|
||||
|
||||
namespace NzbDrone.Integration.Test
|
||||
{
|
||||
[TestFixture]
|
||||
public class SeriesIntegrationTest : IntegrationTest
|
||||
{
|
||||
[Test]
|
||||
public void should_have_no_series_on_start_application()
|
||||
{
|
||||
Series.All().Should().BeEmpty();
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void series_lookup_on_trakt()
|
||||
{
|
||||
var series = Series.Lookup("archer");
|
||||
|
||||
series.Should().NotBeEmpty();
|
||||
series.Should().Contain(c => c.Title == "Archer (2009)");
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void add_series_without_required_fields_should_return_badrequest()
|
||||
{
|
||||
var errors = Series.InvalidPost(new SeriesResource());
|
||||
errors.Should().NotBeEmpty();
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_be_able_to_add_series()
|
||||
{
|
||||
var series = Series.Lookup("archer").First();
|
||||
|
||||
Series.Post(series);
|
||||
|
||||
Series.All().Should().HaveCount(1);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue