"value":"\n <p>Writing custom assertions is a great way to clean up your test code.<\/p>\n\n<p>Here's an example from one of my client Drupal projects:<\/p>\n\n<pre><code class=\"language-php\">private static function assertProductVariationHasPrice(ProductVariationInterface $productVariation, string $expectedPrice): void {\n self::assertSame(\n actual: $productVariation->getPrice()->getNumber(),\n expected: $expectedPrice,\n );\n}\n<\/code><\/pre>\n\n<p>This one wraps a single assertion, but they could also include multiple assertions or additional steps.<\/p>\n\n<h2 id=\"here%27s-the-thing\">Here's the thing<\/h2>\n\n<p>A custom assertion is a simple function but it makes the test code more readable and less repetitive.<\/p>\n\n ",
"format":"full_html",
"processed":"\n <p>Writing custom assertions is a great way to clean up your test code.<\/p>\n\n<p>Here's an example from one of my client Drupal projects:<\/p>\n\n<pre><code class=\"language-php\">private static function assertProductVariationHasPrice(ProductVariationInterface $productVariation, string $expectedPrice): void {\n self::assertSame(\n actual: $productVariation->getPrice()->getNumber(),\n expected: $expectedPrice,\n );\n}\n<\/code><\/pre>\n\n<p>This one wraps a single assertion, but they could also include multiple assertions or additional steps.<\/p>\n\n<h2 id=\"here%27s-the-thing\">Here's the thing<\/h2>\n\n<p>A custom assertion is a simple function but it makes the test code more readable and less repetitive.<\/p>\n\n ",