diff options
Diffstat (limited to 'Zend/tests/traits/bugs/abstract-methods02.phpt')
-rw-r--r-- | Zend/tests/traits/bugs/abstract-methods02.phpt | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/Zend/tests/traits/bugs/abstract-methods02.phpt b/Zend/tests/traits/bugs/abstract-methods02.phpt new file mode 100644 index 0000000..78abe7d --- /dev/null +++ b/Zend/tests/traits/bugs/abstract-methods02.phpt @@ -0,0 +1,26 @@ +--TEST-- +Abstract Trait Methods should behave like common abstract methods. +--FILE-- +<?php +error_reporting(E_ALL); + +trait THello { + public abstract function hello(); +} + +trait THelloImpl { + public function hello() { + echo 'Hello'; + } +} + +class TraitsTest { + use THello; + use THelloImpl; +} + +$test = new TraitsTest(); +$test->hello(); +?> +--EXPECTF-- +Hello
\ No newline at end of file |