await patientlyWaitFor(() => {
    expect(getAllByText('test')[0].closest('a'))
      .toHaveAttribute('href', '/lifecycle_environments/2');
  });