Skip to content

[CLEANUP] Use the explicit OutputFormat setters in the tests #1106

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 7, 2025

Conversation

oliverklee
Copy link
Collaborator

The set() method will be removed soon.

Also unify the tests a bit.

Part of #1103

@coveralls
Copy link

coveralls commented Mar 7, 2025

Coverage Status

coverage: 54.834% (-0.8%) from 55.626%
when pulling 048282b on task/avoid-set-get
into 07b4db0 on main.

@oliverklee oliverklee force-pushed the task/avoid-set-get branch from 0fcad40 to 9eb4feb Compare March 7, 2025 08:45
Copy link
Collaborator

@JakeQZ JakeQZ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One test uses two separate OutputFormats.

@@ -280,6 +310,8 @@ public function ignoreExceptionsOff(): void
{
$this->expectException(OutputException::class);

$outputFormat = OutputFormat::create()->setIgnoreExceptions(false);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test uses two separate OutputFormats.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've now changed it to use the same instance (as it doesn't seem relevant to me to use two instances with identical settings).

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it doesn't seem relevant to me to use two instances with identical settings

Me neither - given that it's just testing that an exception is thrown when attempting to render a declaration block without a selector.

The `set()` method will be removed soon.

Also unify the tests a bit.

Part of #1103
@oliverklee oliverklee force-pushed the task/avoid-set-get branch from 9eb4feb to 504e142 Compare March 7, 2025 14:55
@oliverklee oliverklee requested a review from JakeQZ March 7, 2025 14:57
@JakeQZ JakeQZ merged commit 9e087c5 into main Mar 7, 2025
21 checks passed
@JakeQZ JakeQZ deleted the task/avoid-set-get branch March 7, 2025 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants