diff --git a/core/modules/migrate/tests/src/Kernel/MigrateSourceTestBase.php b/core/modules/migrate/tests/src/Kernel/MigrateSourceTestBase.php
index 8a99cad..f5e5135 100644
--- a/core/modules/migrate/tests/src/Kernel/MigrateSourceTestBase.php
+++ b/core/modules/migrate/tests/src/Kernel/MigrateSourceTestBase.php
@@ -185,6 +185,9 @@ public function testSource(array $source_data, array $expected_data, $expected_c
         }
       }
     }
+    // False positives occur if the foreach is not entered. So, confirm the
+    // foreach loop was entered.
+    $this->assertGreaterThan(0, $i);
   }
 
 }
