Skip to content

Commit

Permalink
Add IdentificationEndpoint.delete
Browse files Browse the repository at this point in the history
  • Loading branch information
spajxo committed Mar 13, 2024
1 parent 6c57c10 commit 7c4f379
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Updates should follow the [Keep a CHANGELOG](http://keepachangelog.com/) princip

## [Unreleased]
### Added
- Add `IdentificationEndpoint.delete`
- Add `IdentifyScenarioVersion.expireAfterHours`
- Add `IdentifyScenarioVersion.discardCompletedAfterDays`
- Add AccountSecurity.discardedIdentificationRetention
Expand Down
2 changes: 2 additions & 0 deletions src/Endpoint/IdentificationsEndpoint.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
namespace DigitalCz\DigiSign\Endpoint;

use DigitalCz\DigiSign\DigiSign;
use DigitalCz\DigiSign\Endpoint\Traits\DeleteEndpointTrait;
use DigitalCz\DigiSign\Endpoint\Traits\GetEndpointTrait;
use DigitalCz\DigiSign\Endpoint\Traits\ListEndpointTrait;
use DigitalCz\DigiSign\Resource\Identification;
Expand All @@ -21,6 +22,7 @@ final class IdentificationsEndpoint extends ResourceEndpoint
/** @use ListEndpointTrait<Identification> */
use ListEndpointTrait;
use GetEndpointTrait;
use DeleteEndpointTrait;

public function __construct(DigiSign $parent)
{
Expand Down
6 changes: 6 additions & 0 deletions tests/Endpoint/IdentificationsEndpointTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ public function testCancel(): void
self::assertLastRequest('POST', '/api/identifications/foo/cancel');
}

public function testDelete(): void
{
self::endpoint()->delete('foo');
self::assertLastRequest('DELETE', '/api/identifications/foo');
}

public function testDiscard(): void
{
self::endpoint()->discard('foo');
Expand Down

0 comments on commit 7c4f379

Please sign in to comment.