AggregatorLocalTasksTest causes the GitLab CI pipeline to time out
>>> [!note] Migrated issue <!-- Drupal.org comment --> <!-- Migrated from issue #3404230. --> Reported by: [dcam](https://www.drupal.org/user/1791830) >>> <p>This test passes on Drupal CI and locally. But GitLab runs and runs on this test until it times out, see <span class="drupalorg-gitlab-issue-link drupalorg-gitlab-link-wrapper"><a href="https://git.drupalcode.org/project/aggregator/-/work_items/3403910" class="drupalorg-gitlab-link">https://git.drupalcode.org/project/aggregator/-/work_items/3403910</a></span>. There's a <code>while</code> loop in there that could easily create an infinite loop:</p> <div class="codeblock"> <pre><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br>&nbsp; </span><span style="color: #007700">protected function </span><span style="color: #0000BB">setUp</span><span style="color: #007700">(): </span><span style="color: #0000BB">void </span><span style="color: #007700">{<br>&nbsp;&nbsp;&nbsp; </span><span style="color: #FF8000">// Find core directory.<br>&nbsp;&nbsp;&nbsp; </span><span style="color: #0000BB">$core_dir </span><span style="color: #007700">= </span><span style="color: #0000BB">__DIR__</span><span style="color: #007700">;<br>&nbsp;&nbsp;&nbsp; while (!</span><span style="color: #0000BB">file_exists</span><span style="color: #007700">(</span><span style="color: #0000BB">$core_dir </span><span style="color: #007700">. </span><span style="color: #DD0000">'/index.php'</span><span style="color: #007700">)) {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span><span style="color: #0000BB">$core_dir </span><span style="color: #007700">= </span><span style="color: #0000BB">dirname</span><span style="color: #007700">(</span><span style="color: #0000BB">$core_dir</span><span style="color: #007700">);<br>&nbsp;&nbsp;&nbsp; }<br>&nbsp;&nbsp;&nbsp; </span><span style="color: #0000BB">$this_dir </span><span style="color: #007700">= </span><span style="color: #0000BB">dirname</span><span style="color: #007700">(</span><span style="color: #0000BB">__DIR__</span><span style="color: #007700">, </span><span style="color: #0000BB">4</span><span style="color: #007700">);<br>&nbsp;&nbsp;&nbsp; </span><span style="color: #0000BB">$relative_path_to_module </span><span style="color: #007700">= </span><span style="color: #0000BB">substr</span><span style="color: #007700">(</span><span style="color: #0000BB">$this_dir</span><span style="color: #007700">, </span><span style="color: #0000BB">strlen</span><span style="color: #007700">(</span><span style="color: #0000BB">$core_dir</span><span style="color: #007700">));<br>&nbsp;&nbsp;&nbsp; </span><span style="color: #0000BB">$this</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">directoryList </span><span style="color: #007700">= [</span><span style="color: #DD0000">'aggregator' </span><span style="color: #007700">=&gt; </span><span style="color: #0000BB">$relative_path_to_module</span><span style="color: #007700">];<br>&nbsp;&nbsp;&nbsp; </span><span style="color: #0000BB">parent</span><span style="color: #007700">::</span><span style="color: #0000BB">setUp</span><span style="color: #007700">();<br>&nbsp; }<br></span><span style="color: #0000BB">?&gt;</span></span></pre></div> > Related issue: [Issue #3403910](https://www.drupal.org/node/3403910)
issue