(dev/core#1412) E2E - Add test case for path+URL construction in CLI
authorTim Otten <totten@civicrm.org>
Thu, 21 Nov 2019 21:58:38 +0000 (13:58 -0800)
committerTim Otten <totten@civicrm.org>
Thu, 21 Nov 2019 22:10:09 +0000 (14:10 -0800)
commit62e2c02736e683dcb199af29dc4d2bddb9dec31d
tree8af20c3e364fe22e9f81246d2917cf2fc5bb3136
parent1a4b897935b8c388d4fb550266a7858eb2761cb5
(dev/core#1412) E2E - Add test case for path+URL construction in CLI

Overview
--------

In dev/core#1412, the regression involved CLI processes producing incorrect URLs.
This adds some test-coverage.

Before
------

No test coverage for URLs in CLI environment.

After
-----

There is some test-coverage. It's able to reveal the existence of the bug from 1412.

Comments
--------

A lot of path/URL construction is dependent on the environment/site-build.
The test does not, on its own, guarantee that all environments work.
Rather, it adds a new slice of cheese to the stack.

This slice is moderately generic - in that I've successfully tested it
localy on `drupal-demo` and `wp-demo` builds.  In theory, it should work on
other build types (as long as they set variables `CIVI_CORE`, `CMS_ROOT`,
`CMS_URL`).
tests/phpunit/E2E/Extern/CliRunnerTest.php [new file with mode: 0644]