mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-22 13:30:55 +01:00
Fix local time test case for logged-out viewers using global settings
Summary: In D16936, I changed logged-out viewers so they use global settings. This can lead to a `SELECT` from an isolated unit test. Instead, give the test fixtures and use standard `generateNewUser()` stuff. Test Plan: Ran `arc unit --everything`. Reviewers: chad Reviewed By: chad Differential Revision: https://secure.phabricator.com/D16952
This commit is contained in:
parent
c5162074a1
commit
ab3b707396
1 changed files with 8 additions and 2 deletions
|
@ -2,11 +2,17 @@
|
|||
|
||||
final class PhabricatorLocalTimeTestCase extends PhabricatorTestCase {
|
||||
|
||||
protected function getPhabricatorTestCaseConfiguration() {
|
||||
return array(
|
||||
self::PHABRICATOR_TESTCONFIG_BUILD_STORAGE_FIXTURES => true,
|
||||
);
|
||||
}
|
||||
|
||||
public function testLocalTimeFormatting() {
|
||||
$user = new PhabricatorUser();
|
||||
$user = $this->generateNewTestUser();
|
||||
$user->overrideTimezoneIdentifier('America/Los_Angeles');
|
||||
|
||||
$utc = new PhabricatorUser();
|
||||
$utc = $this->generateNewTestUser();
|
||||
$utc->overrideTimezoneIdentifier('UTC');
|
||||
|
||||
$this->assertEqual(
|
||||
|
|
Loading…
Reference in a new issue