diff --git a/test/Utils/Flex/FlexExecCommandTest.php b/test/Utils/Flex/FlexExecCommandTest.php
index <HASH>..<HASH> 100644
--- a/test/Utils/Flex/FlexExecCommandTest.php
+++ b/test/Utils/Flex/FlexExecCommandTest.php
@@ -125,10 +125,9 @@ class FlexExecCommandTest extends \PHPUnit_Framework_TestCase
             ]
         );
         // Check the contents of the generated cloudbuild.yaml
-        $cloudbuild = file_get_contents("$this->workdir/cloudbuild.yaml");
-        $this->assertEquals(
-            file_get_contents($cloudbuildYaml),
-            $cloudbuild
+        $this->assertFileEquals(
+            $cloudbuildYaml,
+            sprintf('%s/cloudbuild.yaml', $this->workdir)
         );
     }
Use assertFileEquals (#<I>)