Fixed test cases.
git-svn-id: https://svn.apache.org/repos/asf/incubator/zetacomponents/trunk@1180902 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/Reflection/tests/class_test.php b/Reflection/tests/class_test.php
index 4410cdd..841f1ca 100644
--- a/Reflection/tests/class_test.php
+++ b/Reflection/tests/class_test.php
@@ -174,7 +174,32 @@
public function testGetLongDescription() {
$desc = $this->classTestWebservice->getLongDescription();
- $expected = "This is the long description with may be additional infos and much more lines\nof text.\n\nEmpty lines are valid, too.\n\nfoo bar";
+ $expected = <<<ENDDATA
+This is the long description with may be additional infos and much more lines
+of text.
+
+Empty lines are valid, too.
+
+foo bar
+
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+ENDDATA;
+
self::assertEquals($expected, $desc);
}
diff --git a/Reflection/tests/parser_test.php b/Reflection/tests/parser_test.php
index 588b5c9..c011c9c 100644
--- a/Reflection/tests/parser_test.php
+++ b/Reflection/tests/parser_test.php
@@ -35,7 +35,7 @@
public function testGetAnnotationsByName() {
$parser = ezcReflection::getDocCommentParser();
$parser->parse(self::$docs[0]);
- $annotations = $parser->getAnnotationsByName('copyright');
+ $annotations = $parser->getAnnotationsByName('license');
self::assertEquals(1, count($annotations));
$annotations = $parser->getAnnotationsByName('filesource');
@@ -69,7 +69,7 @@
$parser = ezcReflection::getDocCommentParser();
$parser->parse(self::$docs[0]);
$annotations = $parser->getAnnotations();
- self::assertEquals(6, count($annotations));
+ self::assertEquals(5, count($annotations));
$parser = ezcReflection::getDocCommentParser();
$parser->parse(self::$docs[1]);
@@ -218,7 +218,32 @@
$parser->parse($doc);
$desc = $parser->getLongDescription();
- $expected = "This is the long description with may be additional infos and much more lines\nof text.\n\nEmpty lines are valid, too.\n\nfoo bar";
+ $expected = <<<ENDDATA
+This is the long description with may be additional infos and much more lines
+of text.
+
+Empty lines are valid, too.
+
+foo bar
+
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+ENDDATA;
+
self::assertEquals($expected, $desc);
}