Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
Looks like ConnectionUnitTest doesn't actually get skipped because of a very small logic snafu:
https://git.drupalcode.org/project/drupal/-/blob/7.73/modules/simpletest...
$this->skipTest = (bool) $connection_info['default']['driver'] != 'mysql';
Steps to reproduce
php > var_dump((bool) 'sqlite' != 'mysql');
bool(false)
php > var_dump((bool) ('sqlite' != 'mysql'));
bool(true)
Proposed resolution
Fix the logic so that the test is skipped for non-MySQL drivers.
Remaining tasks
Follow up if we want to fix PostgreSQL tests too at some point - backport of: #3128880: Make ConnectionUnitTest also run for PostgreSQL
...for now though, I'd expect this patch to fix (by skipping) a test which will fail in PostgreSQL.
User interface changes
n/a
API changes
n/a
Data model changes
n/a
Release notes snippet
n/a
Comment | File | Size | Author |
---|---|---|---|
#2 | 3174134-2.patch | 1.02 KB | mcdruid |
Comments
Comment #2
mcdruidn.b. not much point testing this with SQLite in isolation until a couple of the key patches in the parent issue have been committed.
Comment #3
Fabianx CreditAttribution: Fabianx as a volunteer and at Tag1 Consulting commentedRTMB - Approved - thanks!
Comment #5
mcdruidThank you!