public function testDescendantsByNode() { $category = $this->findCategory('notebooks'); $res = all(Category::whereDescendantOf($category)->pluck('id')); $this->assertEquals([3, 4], $res); }