@@ 45-56 (lines=12) @@ | ||
42 | $bib->mms_id->shouldBe($mms_id); |
|
43 | } |
|
44 | ||
45 | public function it_accepts_expand_parameter(AlmaClient $client, UriInterface $url) |
|
46 | { |
|
47 | $client->buildUrl('/bibs/12345', ['expand' => 'p_avail']) |
|
48 | ->shouldBeCalled() |
|
49 | ->willReturn($url); |
|
50 | ||
51 | $client->getJSON($url) |
|
52 | ->shouldBeCalled() |
|
53 | ->willReturn(SpecHelper::getDummyData('bib_response_with_availability.json')); |
|
54 | ||
55 | $this->get('12345', 'p_avail')->record; |
|
56 | } |
|
57 | ||
58 | public function it_provides_lookup_by_isbn(AlmaClient $client, SruClient $sru) |
|
59 | { |
@@ 34-45 (lines=12) @@ | ||
31 | $user->shouldHaveType(User::class); |
|
32 | } |
|
33 | ||
34 | public function it_accepts_additional_parameters(AlmaClient $client, UriInterface $url) |
|
35 | { |
|
36 | $client->buildUrl('/users/12345', ['expand' => 'fees']) |
|
37 | ->shouldBeCalled() |
|
38 | ->willReturn($url); |
|
39 | ||
40 | $client->getJSON($url) |
|
41 | ->shouldBeCalled() |
|
42 | ->willReturn(SpecHelper::getDummyData('user_response.json')); |
|
43 | ||
44 | $this->get('12345', ['expand' => 'fees'])->init(); |
|
45 | } |
|
46 | ||
47 | public function it_provides_lookup_by_id(AlmaClient $client, UriInterface $url) |
|
48 | { |