DrupalWebTestCase->getAbsoluteUrl should use internal browser's base URL

Created on 25 May 2009, about 16 years ago
Updated 18 September 2024, 10 months ago

In DrupalWebTestCase, getAbsoluteUrl eventually calls url(). The url() function uses the $base_url set by the simpletest runner, not the internal web browser. One result of this is it's impossible to POST to an https URL.

🐛 Bug report
Status

Postponed: needs info

Version

7.0 ⚰️

Component
Simpletest 

Last updated 19 days ago

Created by

🇺🇸United States grendzy

Live updates comments and jobs are added and updated live.
  • Needs issue summary update

    Issue summaries save everyone time if they are kept up-to-date. See Update issue summary task instructions.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇦🇺Australia mstrelan

    Is this still relevant? It seems \Drupal\Tests\UiHelperTrait::getAbsoluteUrl is the modern equivalent, which is used in BrowserTestBase and WebDriverTestBase. I don't really understand what the problem is that this issue is trying to solve. I wonder if it's actually more relevant to move this to the simpletest queue? Or shall we make this a 7.x issue if it only applies to simpletest.

  • 🇦🇺Australia mstrelan

    Discussed in #bugsmash and I think we can set this back to 7.x against the simpletest component. Other tags still apply. If there is a case for this in Drupal 11 / phpunit then feel free to undo these changes.

Production build 0.71.5 2024