@@ 111-120 (lines=10) @@ | ||
108 | ])->shouldReturn(false); |
|
109 | } |
|
110 | ||
111 | function it_matches_if_resource_matches(FieldNode $f1, ResourceNode $resource) |
|
112 | { |
|
113 | $f1->matches('search-value1')->willReturn(true); |
|
114 | $resource->matches(['resource_field' => 'search-value2'])->willReturn(true); |
|
115 | ||
116 | $this->matches([ |
|
117 | 'field1' => 'search-value1', |
|
118 | ['resource', 'resource1', ['resource_field' => 'search-value2']], |
|
119 | ])->shouldReturn(true); |
|
120 | } |
|
121 | ||
122 | function it_does_not_match_if_resource_does_not_match(FieldNode $f1, ResourceNode $resource) |
|
123 | { |
|
@@ 122-131 (lines=10) @@ | ||
119 | ])->shouldReturn(true); |
|
120 | } |
|
121 | ||
122 | function it_does_not_match_if_resource_does_not_match(FieldNode $f1, ResourceNode $resource) |
|
123 | { |
|
124 | $f1->matches('search-value1')->willReturn(true); |
|
125 | $resource->matches(['resource_field' => 'search-value2'])->willReturn(false); |
|
126 | ||
127 | $this->matches([ |
|
128 | 'field1' => 'search-value1', |
|
129 | ['resource', 'resource1', ['resource_field' => 'search-value2']], |
|
130 | ])->shouldReturn(false); |
|
131 | } |
|
132 | } |
|
133 |