I use PHP-Parser in my project. I would like to compare two nodes, using PHPUnit's assertSame function.
Despite the nodes are the same, it gives a false result. The reason is, that one of the nodes contains this, and the other does not:
["attributes":protected]=>
array(2) {
["startLine"]=>
int(2)
["endLine"]=>
int(2)
}
Is it possible to compare the nodes without protected attributes?
Aucun commentaire:
Enregistrer un commentaire