Skip to content

Fix unit test after reordering the constructor parameters - #41

Merged
pavog merged 1 commit into
masterfrom
fix-configuration-test
Oct 19, 2026
Merged

pavog merged 1 commit into
masterfrom
fix-configuration-test

Conversation

@pavog

@pavog pavog commented Oct 19, 2026

Copy link
Copy Markdown
Member

The unit tests on master fail since #36 was merged:

TypeError: HangarAPIClient::__construct(): Argument #1 ($apiKey) must be of type ?string, Aternos\HangarApi\Configuration given

testBooleanQueryParametersAreSentAsStringWithCustomConfiguration() was added in #35 and passes the configuration as the first argument of the constructor. #36 changed the order of the parameters, so the API key is now the first one. Both PRs passed on their own, the failure only happens after both were merged.

Changes

  • The test creates the client with createClient() of the test case and passes the configuration by name, like the other tests.
  • The Guzzle imports that are no longer used are removed.

@pavog
pavog merged commit bbe429d into master Oct 19, 2026
3 checks passed
@pavog
pavog deleted the fix-configuration-test branch October 19, 2026 14:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant