$s1 = "Hello"; $s2 = "Hello"; $this->assertSame($s1, $s2);
$a1 = array(1, 2, 3); $a2 = array(1, 2, 3); $this->assertSame($a1, $a2);In this example, we create two arrays and use the assertSame method to test if they are the same. Since they have the same value and type, the test will pass. The PHPUnit_Framework_Assert class is part of the PHPUnit package library.