Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add test for TRAC-1021.

  • Loading branch information...
commit 8442ae22e67ee132a494fb65bcef9ad61665a0e8 1 parent b5a059a
@sebastianbergmann authored
View
19 PHPUnit/Tests/Regression/1021.phpt
@@ -0,0 +1,19 @@
+--TEST--
+#1021: Depending on a test that uses a data provider does not work
+--FILE--
+<?php
+$_SERVER['argv'][1] = '--no-configuration';
+$_SERVER['argv'][2] = 'Issue1021Test';
+$_SERVER['argv'][3] = 'Regression/1021/Issue1021Test.php';
+
+require_once dirname(dirname(dirname(__FILE__))) . '/TextUI/Command.php';
+PHPUnit_TextUI_Command::main();
+?>
+--EXPECTF--
+PHPUnit %s by Sebastian Bergmann.
+
+..
+
+Time: %i %s, Memory: %sMb
+
+OK (2 tests, 1 assertion)
View
23 PHPUnit/Tests/Regression/1021/Issue1021Test.php
@@ -0,0 +1,23 @@
+<?php
+class Issue1021Test extends PHPUnit_Framework_TestCase
+{
+ /**
+ * @dataProvider provider
+ */
+ public function testSomething($data)
+ {
+ $this->assertTrue($data);
+ }
+
+ /**
+ * @depends testSomething
+ */
+ public function testSomethingElse()
+ {
+ }
+
+ public function provider()
+ {
+ return array(array(true));
+ }
+}
Please sign in to comment.
Something went wrong with that request. Please try again.