Skip to content

Commit

Permalink
chore: add test cases for returning types of unsealed results
Browse files Browse the repository at this point in the history
  • Loading branch information
Orkuncakilkaya committed Aug 20, 2024
1 parent bdfb252 commit 123f039
Show file tree
Hide file tree
Showing 48 changed files with 440 additions and 146 deletions.
4 changes: 3 additions & 1 deletion src/Model/ASN.php
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,8 @@ public function setNetwork(string $network): self

/**
* Gets name.
*
* @return ?string
*/
public function getName(): ?string
{
Expand All @@ -265,7 +267,7 @@ public function getName(): ?string
/**
* Sets name.
*
* @param string $name name
* @param ?string $name name
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/BotdDetectionResult.php
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,8 @@ public function setResult(string $result): self

/**
* Gets type.
*
* @return ?string
*/
public function getType(): ?string
{
Expand All @@ -269,7 +271,7 @@ public function getType(): ?string
/**
* Sets type.
*
* @param string $type type
* @param ?string $type type
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/BotdResult.php
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,8 @@ public function setRequestId(string $request_id): self

/**
* Gets linked_id.
*
* @return ?string
*/
public function getLinkedId(): ?string
{
Expand All @@ -369,7 +371,7 @@ public function getLinkedId(): ?string
/**
* Sets linked_id.
*
* @param string $linked_id linked_id
* @param ?string $linked_id linked_id
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/BrowserDetails.php
Original file line number Diff line number Diff line change
Expand Up @@ -411,6 +411,8 @@ public function setUserAgent(string $user_agent): self

/**
* Gets bot_probability.
*
* @return ?int
*/
public function getBotProbability(): ?int
{
Expand All @@ -420,7 +422,7 @@ public function getBotProbability(): ?int
/**
* Sets bot_probability.
*
* @param int $bot_probability bot_probability
* @param ?int $bot_probability bot_probability
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/DataCenter.php
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,8 @@ public function setResult(bool $result): self

/**
* Gets name.
*
* @return ?string
*/
public function getName(): ?string
{
Expand All @@ -234,7 +236,7 @@ public function getName(): ?string
/**
* Sets name.
*
* @param string $name name
* @param ?string $name name
*
* @return $this
*/
Expand Down
36 changes: 26 additions & 10 deletions src/Model/DeprecatedIPLocation.php
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,8 @@ public function valid(): bool

/**
* Gets accuracy_radius.
*
* @return ?int
*/
public function getAccuracyRadius(): ?int
{
Expand All @@ -250,7 +252,7 @@ public function getAccuracyRadius(): ?int
/**
* Sets accuracy_radius.
*
* @param int $accuracy_radius the IP address is likely to be within this radius (in km) of the specified location
* @param ?int $accuracy_radius the IP address is likely to be within this radius (in km) of the specified location
*
* @return $this
*/
Expand All @@ -263,6 +265,8 @@ public function setAccuracyRadius(?int $accuracy_radius): self

/**
* Gets latitude.
*
* @return ?double
*/
public function getLatitude(): ?float
{
Expand All @@ -272,7 +276,7 @@ public function getLatitude(): ?float
/**
* Sets latitude.
*
* @param float $latitude latitude
* @param ?double $latitude latitude
*
* @return $this
*/
Expand All @@ -285,6 +289,8 @@ public function setLatitude(?float $latitude): self

/**
* Gets longitude.
*
* @return ?double
*/
public function getLongitude(): ?float
{
Expand All @@ -294,7 +300,7 @@ public function getLongitude(): ?float
/**
* Sets longitude.
*
* @param float $longitude longitude
* @param ?double $longitude longitude
*
* @return $this
*/
Expand All @@ -307,6 +313,8 @@ public function setLongitude(?float $longitude): self

/**
* Gets postal_code.
*
* @return ?string
*/
public function getPostalCode(): ?string
{
Expand All @@ -316,7 +324,7 @@ public function getPostalCode(): ?string
/**
* Sets postal_code.
*
* @param string $postal_code postal_code
* @param ?string $postal_code postal_code
*
* @return $this
*/
Expand All @@ -329,6 +337,8 @@ public function setPostalCode(?string $postal_code): self

/**
* Gets timezone.
*
* @return ?string
*/
public function getTimezone(): ?string
{
Expand All @@ -338,7 +348,7 @@ public function getTimezone(): ?string
/**
* Sets timezone.
*
* @param string $timezone timezone
* @param ?string $timezone timezone
*
* @return $this
*/
Expand All @@ -351,6 +361,8 @@ public function setTimezone(?string $timezone): self

/**
* Gets city.
*
* @return ?\Fingerprint\ServerAPI\Model\DeprecatedIPLocationCity
*/
public function getCity(): ?DeprecatedIPLocationCity
{
Expand All @@ -360,7 +372,7 @@ public function getCity(): ?DeprecatedIPLocationCity
/**
* Sets city.
*
* @param DeprecatedIPLocationCity $city city
* @param ?\Fingerprint\ServerAPI\Model\DeprecatedIPLocationCity $city city
*
* @return $this
*/
Expand All @@ -373,6 +385,8 @@ public function setCity(?DeprecatedIPLocationCity $city): self

/**
* Gets country.
*
* @return ?\Fingerprint\ServerAPI\Model\Location
*/
public function getCountry(): ?Location
{
Expand All @@ -382,7 +396,7 @@ public function getCountry(): ?Location
/**
* Sets country.
*
* @param Location $country country
* @param ?\Fingerprint\ServerAPI\Model\Location $country country
*
* @return $this
*/
Expand All @@ -395,6 +409,8 @@ public function setCountry(?Location $country): self

/**
* Gets continent.
*
* @return ?\Fingerprint\ServerAPI\Model\Location
*/
public function getContinent(): ?Location
{
Expand All @@ -404,7 +420,7 @@ public function getContinent(): ?Location
/**
* Sets continent.
*
* @param Location $continent continent
* @param ?\Fingerprint\ServerAPI\Model\Location $continent continent
*
* @return $this
*/
Expand All @@ -418,7 +434,7 @@ public function setContinent(?Location $continent): self
/**
* Gets subdivisions.
*
* @return \Fingerprint\ServerAPI\Model\Subdivision[]
* @return ?\Fingerprint\ServerAPI\Model\Subdivision[]
*/
public function getSubdivisions(): ?array
{
Expand All @@ -428,7 +444,7 @@ public function getSubdivisions(): ?array
/**
* Sets subdivisions.
*
* @param \Fingerprint\ServerAPI\Model\Subdivision[] $subdivisions subdivisions
* @param ?\Fingerprint\ServerAPI\Model\Subdivision[] $subdivisions subdivisions
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/DeprecatedIPLocationCity.php
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,8 @@ public function valid(): bool

/**
* Gets name.
*
* @return ?string
*/
public function getName(): ?string
{
Expand All @@ -200,7 +202,7 @@ public function getName(): ?string
/**
* Sets name.
*
* @param string $name name
* @param ?string $name name
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/ErrorEvent403Response.php
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,8 @@ public function valid(): bool

/**
* Gets error.
*
* @return ?\Fingerprint\ServerAPI\Model\ErrorEvent403ResponseError
*/
public function getError(): ?ErrorEvent403ResponseError
{
Expand All @@ -200,7 +202,7 @@ public function getError(): ?ErrorEvent403ResponseError
/**
* Sets error.
*
* @param ErrorEvent403ResponseError $error error
* @param ?\Fingerprint\ServerAPI\Model\ErrorEvent403ResponseError $error error
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/ErrorEvent404Response.php
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,8 @@ public function valid(): bool

/**
* Gets error.
*
* @return ?\Fingerprint\ServerAPI\Model\ErrorEvent404ResponseError
*/
public function getError(): ?ErrorEvent404ResponseError
{
Expand All @@ -200,7 +202,7 @@ public function getError(): ?ErrorEvent404ResponseError
/**
* Sets error.
*
* @param ErrorEvent404ResponseError $error error
* @param ?\Fingerprint\ServerAPI\Model\ErrorEvent404ResponseError $error error
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/EventResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,8 @@ public function setProducts(ProductsResponse $products): self

/**
* Gets error.
*
* @return ?\Fingerprint\ServerAPI\Model\ProductError
*/
public function getError(): ?ProductError
{
Expand All @@ -236,7 +238,7 @@ public function getError(): ?ProductError
/**
* Sets error.
*
* @param ProductError $error error
* @param ?\Fingerprint\ServerAPI\Model\ProductError $error error
*
* @return $this
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Model/HighActivityResult.php
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,8 @@ public function setResult(bool $result): self

/**
* Gets daily_requests.
*
* @return ?float
*/
public function getDailyRequests(): ?float
{
Expand All @@ -234,7 +236,7 @@ public function getDailyRequests(): ?float
/**
* Sets daily_requests.
*
* @param float $daily_requests number of requests from the same visitor in the previous day
* @param ?float $daily_requests number of requests from the same visitor in the previous day
*
* @return $this
*/
Expand Down
Loading

0 comments on commit 123f039

Please sign in to comment.