public function AcquiaSPITestCase::testAcquiaHosted in Acquia Connector 7.3
Test acquia_spi_check_acquia_hosted() function.
File
- acquia_spi/
tests/ acquia_spi.test, line 466
Class
- AcquiaSPITestCase
- Tests the functionality of the Acquia SPI module.
Code
public function testAcquiaHosted() {
$server = array();
variable_set('acquia_agent_server_superglobal', $server);
$this
->assertFalse(acquia_spi_check_acquia_hosted(), 'Site is not hosted with Acquia');
$server = array(
'AH_SITE_NAME' => 'site_name',
'AH_SITE_ENVIRONMENT' => 'dev',
);
variable_set('acquia_agent_server_superglobal', $server);
$this
->assertTrue(acquia_spi_check_acquia_hosted(), 'Site is hosted with Acquia');
variable_del('acquia_agent_server_superglobal');
}