Comments (7)
Duplicate of #30.
from comparator.
Hello Friends,
I am tried to do write some phpunit test cases in zend framework2.
When run the phpunit command and I am getting below errors:
PHP Fatal error: Declaration of PHPUnit_Framework_Comparator_DOMDocument::assertEquals($expected, $actual, $delta = 0, $canonicalize = false, $ignoreCase = false) must be compatible with PHPUnit_Framework_Comparator_Object::assertEquals($expected, $actual, $delta = 0, $canonicalize = false, $ignoreCase = false, array &$processed = Array) in C:\xampp\php\pear\PHPUnit\Framework\Comparator\DOMDocument.php on line 114
Fatal error: Declaration of PHPUnit_Framework_Comparator_DOMDocument::assertEquals($expected, $actual, $delta = 0, $canonicalize = false, $ignoreCase = false) must be compatible with PHPUnit_Framework_Comparator_Object::assertEquals($expected, $actual, $delta = 0, $canonicalize = false, $ignoreCase = false, array &$processed = Array) in C:\xampp\php\pear\PHPUnit\Framework\Comparator\DOMDocument.php on line 114
I did not get any solutions for same.
My controller code below:
setApplicationConfig(
include './config/application.config.php'
);
parent::setUp();
}
public function testIndexActionCanBeAccessed()
{
$this->dispatch('/users');
$this->assertResponseStatusCode(200);
$this->assertModuleName('Album');
$this->assertControllerName('Album\Controller\Album');
$this->assertControllerClass('AlbumController');
$this->assertMatchedRouteName('album');
}
}
?>
Please help me. Thanks!
from comparator.
Same issue. Please help!!
from comparator.
Oh sorry, I couldn't find an issue in the queue so I opened it
from comparator.
Please check your Zend version, Basically, I have the issue but due to some Zend framework version. Mistakenly I have installed Zend 3 framework and PHPUnit test cases written in Zend 2 framework.
Please once check. I hope your problem will get resolved.
While install the Zend framework give forcefully Zend version name so that you will get install exact version whatever you want.
Thanks
from comparator.
Just ran into this issue in Symfony 4.3 while using persist()
on an ObjectManager
instance.
from comparator.
I found this error writing an assertion in a test;
// Represent a Ticket through a custom class.
$ticket = new Ticket;
// Represent a Ticket through SimpleXMLElement.
$xml = new SimpleXMLElement("/path/to/xml");
// Put equal values in $ticket and $xml.
// Both the operand are string for sure.
$this->assertEquals($ticket->assigned_user_id, $xml->AssignedUserID);
I hope this can help to investigate the issue.
from comparator.
Related Issues (20)
- Compare arrays of strings ignoring line endings
- Regression in 3.0.4 and 4.0.7 HOT 3
- ArrayComparator::assertEquals declaration not compatible with Comparator::assertEquals HOT 4
- Float comparison in 4.0.8 HOT 1
- Honor $canonicalize parameter in `DOMNodeComparator::assertEquals`
- comparation fails for 0 = NULL HOT 1
- Mac OS - MAMP - phpunit fails silently with error in log file HOT 2
- Array comparator should highlight the difference? HOT 4
- XML encoding is lost on canonicalization HOT 4
- Modernize build automation
- ArrayComparator#assertEquals(), canonicalizing stops it from comparing array keys HOT 2
- Fix issues identified by Psalm that are currently ignored (baseline) HOT 1
- Canonicalizing array comparator leaks notices HOT 1
- Warning with PHP 7.4
- Comporator for Strings
- Version 4.0.1 breaks backward compatibility HOT 3
- DOMNodeComparator fails if Node has no Document HOT 2
- DOMNodeComparator::nodeToText used C14N but don't do anything when it fail. HOT 7
- PHP 8.0 Support HOT 2
- DateTimeComparator is invalid HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from comparator.