Commit 5edb2ce 1 parent 2fe9c86 commit 5edb2ce Copy full SHA for 5edb2ce
File tree 1 file changed +10
-1
lines changed
spec/drupol/phptree/Exporter
1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,15 @@ public function getMatchers(): array
25
25
'haveSameGraphImageFile ' => function ($ subject , $ key ) {
26
26
$ left = (new GraphViz ())->setFormat ('png ' )->createImageFile ($ subject );
27
27
28
+ $ left = file_get_contents ($ left );
29
+ print_r ('file_get_contents($left) ' );
30
+ print_r ($ left );
31
+ print_r (sha1 ($ left ));
32
+
33
+ print_r ('right ' );
34
+ print_r (file_get_contents ($ key ));
35
+ print_r (sha1 (file_get_contents ($ key )));
36
+
28
37
return \sha1 (\file_get_contents ($ left )) === \sha1 (\file_get_contents ($ key ));
29
38
},
30
39
];
@@ -52,7 +61,7 @@ public function it_can_generate_a_graph()
52
61
53
62
$ this
54
63
->export ($ tree )
55
- ->shouldHaveSameGraphImageFile (' tests/fixtures/Exporter/GraphSpec1.png ' );
64
+ ->shouldHaveSameGraphImageFile ($ _SERVER [ ' PWD ' ] . ' / tests/fixtures/Exporter/GraphSpec1.png ' );
56
65
}
57
66
58
67
public function it_is_initializable ()
You can’t perform that action at this time.
0 commit comments