@@ -37,25 +37,6 @@ public function test_it_can_add_sources_to_result(): void
3737 static ::assertSame ('See the docs for more info ' , $ sources [0 ]->content );
3838 }
3939
40- public function test_it_includes_sources_in_json_serialization (): void
41- {
42- $ result = $ this ->createResult ();
43- $ result ->sources ()->add (
44- new Source ('Docs ' , 'https://docs.example.com ' , 'See docs ' ),
45- new Source ('Help ' , 'https://help.example.com ' , 'Need help ' )
46- );
47-
48- $ json = json_encode ($ result , JSON_THROW_ON_ERROR );
49- $ data = json_decode ($ json , true , 512 , JSON_THROW_ON_ERROR );
50-
51- static ::assertArrayHasKey ('sources ' , $ data );
52- static ::assertCount (2 , $ data ['sources ' ]);
53- static ::assertSame ('Docs ' , $ data ['sources ' ][0 ]['name ' ]);
54- static ::assertSame ('https://docs.example.com ' , $ data ['sources ' ][0 ]['reference ' ]);
55- static ::assertSame ('See docs ' , $ data ['sources ' ][0 ]['content ' ]);
56- static ::assertSame ('Help ' , $ data ['sources ' ][1 ]['name ' ]);
57- }
58-
5940 public function test_it_can_add_multiple_sources_at_once (): void
6041 {
6142 $ result = $ this ->createResult ();
0 commit comments