public void ShouldReturnOriginalThumbnailUrlWhenEmpty() { var util = new GeoNetworkUtil(BaseUrl); string thumbnailUrl = util.GetThumbnailUrl(Uuid, ""); thumbnailUrl.Should().Be(""); }
public void ShouldReturnThumbnailUrlFromGeoNetworkWhenThumbnailOnlyContainsFilename() { var util = new GeoNetworkUtil(BaseUrl); string exampleImage = "myimage.png"; string thumbnailUrl = util.GetThumbnailUrl(Uuid, exampleImage); thumbnailUrl.Should().Be(BaseUrl + "srv/nor/resources.get?uuid=" + Uuid + "&access=public&fname=" + exampleImage); }
public void ShouldReturnOriginalThumbnailUrlWhenUrlStartsWithHttp() { var util = new GeoNetworkUtil(BaseUrl); string exampleImage = "http://example.com/myimage.png"; string thumbnailUrl = util.GetThumbnailUrl(Uuid, exampleImage); thumbnailUrl.Should().Be(exampleImage); }