From d506ffbd300d43addcf9caff09822bc001e79cb6 Mon Sep 17 00:00:00 2001 From: Jakub Vrana Date: Wed, 24 Oct 2012 12:47:53 -0700 Subject: [PATCH] Add regression test for LiskDAO::__call() Summary: D3606 Test Plan: Deleted `call()`, ran the test. Reviewers: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D3814 --- src/__phutil_library_map__.php | 2 ++ .../lisk/__tests__/LiskDAOTestCase.php | 33 +++++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100644 src/infrastructure/storage/lisk/__tests__/LiskDAOTestCase.php diff --git a/src/__phutil_library_map__.php b/src/__phutil_library_map__.php index 7691b260b7..e988a43cfc 100644 --- a/src/__phutil_library_map__.php +++ b/src/__phutil_library_map__.php @@ -486,6 +486,7 @@ phutil_register_library_map(array( 'JavelinViewExampleServerView' => 'applications/uiexample/examples/JavelinViewExampleServerView.php', 'LiskDAO' => 'infrastructure/storage/lisk/LiskDAO.php', 'LiskDAOSet' => 'infrastructure/storage/lisk/LiskDAOSet.php', + 'LiskDAOTestCase' => 'infrastructure/storage/lisk/__tests__/LiskDAOTestCase.php', 'LiskEphemeralObjectException' => 'infrastructure/storage/lisk/LiskEphemeralObjectException.php', 'LiskFixtureTestCase' => 'infrastructure/storage/lisk/__tests__/LiskFixtureTestCase.php', 'LiskIsolationTestCase' => 'infrastructure/storage/lisk/__tests__/LiskIsolationTestCase.php', @@ -1686,6 +1687,7 @@ phutil_register_library_map(array( 'JavelinUIExample' => 'PhabricatorUIExample', 'JavelinViewExample' => 'PhabricatorUIExample', 'JavelinViewExampleServerView' => 'AphrontView', + 'LiskDAOTestCase' => 'PhabricatorTestCase', 'LiskEphemeralObjectException' => 'Exception', 'LiskFixtureTestCase' => 'PhabricatorTestCase', 'LiskIsolationTestCase' => 'PhabricatorTestCase', diff --git a/src/infrastructure/storage/lisk/__tests__/LiskDAOTestCase.php b/src/infrastructure/storage/lisk/__tests__/LiskDAOTestCase.php new file mode 100644 index 0000000000..d2737ca4c5 --- /dev/null +++ b/src/infrastructure/storage/lisk/__tests__/LiskDAOTestCase.php @@ -0,0 +1,33 @@ +getData(); + + $this->assertException('Exception', array($this, 'getData')); + } + + public function getData() { + $isolation = new LiskIsolationTestDAO(); + $isolation->getData(); + } + +}