-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "Change: update test fixtures and adjust tests"
This reverts commit c632976.
- Loading branch information
Showing
4 changed files
with
19 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,11 +27,11 @@ public class DomainsEmailForwardsTest | |
"deleteEmailForward/success.http"; | ||
|
||
private DateTime CreatedAt { get; } = DateTime.ParseExact( | ||
"2017-05-25T19:23:16Z", "yyyy-MM-ddTHH:mm:ssZ", | ||
"2016-02-04T13:59:29Z", "yyyy-MM-ddTHH:mm:ssZ", | ||
CultureInfo.CurrentCulture); | ||
|
||
private DateTime UpdatedAt { get; } = DateTime.ParseExact( | ||
"2017-05-25T19:23:16Z", "yyyy-MM-ddTHH:mm:ssZ", | ||
"2016-02-04T13:59:29Z", "yyyy-MM-ddTHH:mm:ssZ", | ||
CultureInfo.CurrentCulture); | ||
|
||
[SetUp] | ||
|
@@ -49,9 +49,9 @@ public void EmailForwardsData() | |
|
||
Assert.Multiple(() => | ||
{ | ||
Assert.That(emailForwards.Count, Is.EqualTo(1)); | ||
Assert.That(emailForwards.First().Id, Is.EqualTo(24809)); | ||
Assert.That(emailForwards.First().DomainId, Is.EqualTo(235146)); | ||
Assert.That(emailForwards.Count, Is.EqualTo(2)); | ||
Assert.That(emailForwards.First().Id, Is.EqualTo(17702)); | ||
Assert.That(emailForwards.First().DomainId, Is.EqualTo(228963)); | ||
Assert.That(emailForwards.First().From, Is.EqualTo(".*@a-domain.com")); | ||
Assert.That(emailForwards.First().To, Is.EqualTo("[email protected]")); | ||
Assert.That(emailForwards.First().CreatedAt, Is.EqualTo(CreatedAt)); | ||
|
@@ -73,7 +73,7 @@ public void ListEmailForwards(long accountId, string domainIdentifier, | |
|
||
Assert.Multiple(() => | ||
{ | ||
Assert.That(emailForwards.Data.Count, Is.EqualTo(1)); | ||
Assert.That(emailForwards.Data.Count, Is.EqualTo(2)); | ||
Assert.That(emailForwards.Pagination.CurrentPage, Is.EqualTo(1)); | ||
|
||
Assert.That(client.RequestSentTo(), Is.EqualTo(expectedUrl)); | ||
|
@@ -98,7 +98,7 @@ public void ListEmailForwardsWithOptions(long accountId, | |
|
||
Assert.Multiple(() => | ||
{ | ||
Assert.That(emailForwards.Data.Count, Is.EqualTo(1)); | ||
Assert.That(emailForwards.Data.Count, Is.EqualTo(2)); | ||
Assert.That(emailForwards.Pagination.CurrentPage, Is.EqualTo(1)); | ||
|
||
Assert.That(client.RequestSentTo(), Is.EqualTo(expectedUrl)); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,6 @@ HTTP/1.1 201 Created | |
Server: nginx | ||
Date: Mon, 25 Jan 2021 13:54:40 GMT | ||
Content-Type: application/json; charset=utf-8 | ||
Transfer-Encoding: identity | ||
Connection: keep-alive | ||
X-RateLimit-Limit: 4800 | ||
X-RateLimit-Remaining: 4772 | ||
|
@@ -19,4 +18,4 @@ X-Permitted-Cross-Domain-Policies: none | |
Content-Security-Policy: frame-ancestors 'none' | ||
Strict-Transport-Security: max-age=31536000 | ||
|
||
{"data":{"id":41872,"domain_id":235146,"alias_email":"[email protected]","destination_email":"[email protected]","created_at":"2021-01-25T13:54:40Z","updated_at":"2021-01-25T13:54:40Z","from":"[email protected]","to":"[email protected]"}} | ||
{"data":{"id":41872,"domain_id":235146,"alias_email":"[email protected]","destination_email":"[email protected]","created_at":"2021-01-25T13:54:40Z","updated_at":"2021-01-25T13:54:40Z","from":"[email protected]","to":"[email protected]"}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,6 @@ HTTP/1.1 200 OK | |
Server: nginx | ||
Date: Mon, 25 Jan 2021 13:56:24 GMT | ||
Content-Type: application/json; charset=utf-8 | ||
Transfer-Encoding: identity | ||
Connection: keep-alive | ||
X-RateLimit-Limit: 4800 | ||
X-RateLimit-Remaining: 4766 | ||
|
@@ -19,4 +18,4 @@ X-Permitted-Cross-Domain-Policies: none | |
Content-Security-Policy: frame-ancestors 'none' | ||
Strict-Transport-Security: max-age=31536000 | ||
|
||
{"data":{"id":41872,"domain_id":235146,"alias_email":"[email protected]","destination_email":"[email protected]","created_at":"2021-01-25T13:54:40Z","updated_at":"2021-01-25T13:54:40Z","from":"[email protected]","to":"[email protected]"}} | ||
{"data":{"id":41872,"domain_id":235146,"alias_email":"[email protected]","destination_email":"[email protected]","created_at":"2021-01-25T13:54:40Z","updated_at":"2021-01-25T13:54:40Z","from":"[email protected]","to":"[email protected]"}} |
20 changes: 10 additions & 10 deletions
20
src/dnsimple-test/fixtures/v2/api/listEmailForwards/success.http
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
HTTP/1.1 200 OK | ||
Server: nginx | ||
Date: Fri, 17 May 2024 09:07:28 GMT | ||
Date: Thu, 04 Feb 2016 14:07:19 GMT | ||
Content-Type: application/json; charset=utf-8 | ||
Connection: keep-alive | ||
X-RateLimit-Limit: 4800 | ||
X-RateLimit-Remaining: 4748 | ||
X-RateLimit-Reset: 1715936948 | ||
X-WORK-WITH-US: Love automation? So do we! https://dnsimple.com/jobs | ||
ETag: W/"a5eed9a071f03e10fc67001ccc647a94" | ||
Status: 200 OK | ||
X-RateLimit-Limit: 4000 | ||
X-RateLimit-Remaining: 3993 | ||
X-RateLimit-Reset: 1454596043 | ||
ETag: W/"3f10aae0cf0f0b81bdb4f58786ee1750" | ||
Cache-Control: max-age=0, private, must-revalidate | ||
X-Request-Id: e42df983-a8a5-4123-8c74-fb89ab934aba | ||
X-Runtime: 0.025456 | ||
Strict-Transport-Security: max-age=63072000 | ||
X-Request-Id: 6e3aa9d0-cb95-4186-93b0-630da372de86 | ||
X-Runtime: 0.026287 | ||
Strict-Transport-Security: max-age=31536000 | ||
|
||
{"data":[{"id":24809,"domain_id":235146,"alias_email":".*@a-domain.com","destination_email":"[email protected]","created_at":"2017-05-25T19:23:16Z","updated_at":"2017-05-25T19:23:16Z","from":".*@a-domain.com","to":"jane.smith@example.com"}],"pagination":{"current_page":1,"per_page":30,"total_entries":1,"total_pages":1}} | ||
{"data":[{"id":17702,"domain_id":228963,"from":".*@a-domain.com","to":"[email protected]","created_at":"2016-02-04T13:59:29Z","updated_at":"2016-02-04T13:59:29Z"},{"id":17703,"domain_id":228963,"from":"john@a-domain.com","to":"john@example.com","created_at":"2016-02-04T14:07:13Z","updated_at":"2016-02-04T14:07:13Z"}],"pagination":{"current_page":1,"per_page":30,"total_entries":2,"total_pages":1}} |