feat(coderd): add filters and fix template for provisioner daemons (#16558)

This change adds provisioner daemon ID filter to the provisioner daemons
endpoint, and also implements the limiting to 50 results.

Test coverage is greatly improved and template information for jobs
associated to the daemon was also fixed.

Updates #15084
Updates #15192
Related #16532
This commit is contained in:
Mathias Fredriksson
2025-02-14 17:26:46 +02:00
committed by GitHub
parent a69961bbd2
commit 77306f3de1
13 changed files with 532 additions and 64 deletions

View File

@ -990,7 +990,9 @@ func TestGetProvisionerDaemons(t *testing.T) {
require.NoError(t, err)
require.Len(t, allDaemons, 1)
daemonsAsFound, err := orgAdmin.OrganizationProvisionerDaemons(ctx, org.ID, tt.tagsToFilterBy)
daemonsAsFound, err := orgAdmin.OrganizationProvisionerDaemons(ctx, org.ID, &codersdk.OrganizationProvisionerDaemonsOptions{
Tags: tt.tagsToFilterBy,
})
if tt.expectToGetDaemon {
require.NoError(t, err)
require.Len(t, daemonsAsFound, 1)