File tree Expand file tree Collapse file tree 2 files changed +47
-1
lines changed Expand file tree Collapse file tree 2 files changed +47
-1
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ function test_log()
2929
3030 ray (true , false );
3131
32- ray ($ this );
32+ ray (ray () );
3333
3434 ray (['a ' => 1 , 'b ' => ['c ' => 3 ]]);
3535
Original file line number Diff line number Diff line change 1+ <?php
2+ declare (strict_types=1 );
3+
4+ namespace Tests \Feature ;
5+
6+ use Symfony \Component \VarDumper \VarDumper ;
7+ use Tests \TestCase ;
8+
9+ class VarDumperTest extends TestCase
10+ {
11+ protected function setUp (): void
12+ {
13+ parent ::setUp ();
14+
15+ ray ()->disable ();
16+
17+ VarDumper::setHandler ();
18+ $ _SERVER ['VAR_DUMPER_FORMAT ' ] = 'server ' ;
19+ }
20+
21+ function test_dump ()
22+ {
23+ dump ('Hello ' , 'World ' );
24+
25+ dump (['an array ' ]);
26+
27+ dump (true , false );
28+
29+ dump (ray ());
30+
31+ dump (['a ' => 1 , 'b ' => ['c ' => 3 ]]);
32+
33+ $ this ->assertTrue (true );
34+ }
35+
36+ function test_exception ()
37+ {
38+ try {
39+ throw new \Exception ('Something went wrong ' );
40+ } catch (\Exception $ e ) {
41+ dump ($ e );
42+ }
43+
44+ $ this ->assertTrue (true );
45+ }
46+ }
You can’t perform that action at this time.
0 commit comments