示例#1
0
 public function testGetFieldsByChannelCollection()
 {
     $channels = Channel::where('channel_id', 1)->get();
     $fields = $this->repository->getFieldsByChannelCollection($channels);
     $ids = [];
     foreach ($fields as $field) {
         $ids[] = $field->field_id;
     }
     $this->assertThat($ids, new ArrayHasOnlyValuesConstraint([1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22]));
 }