( t testing.TB, db database.Store, authInstanceID string, name string, createdAt time.Time, jobType database.ProvisionerJobType, )
| 7764 | } |
| 7765 | |
| 7766 | func setupProvisionerJobAgentQueryFixture( |
| 7767 | t testing.TB, |
| 7768 | db database.Store, |
| 7769 | authInstanceID string, |
| 7770 | name string, |
| 7771 | createdAt time.Time, |
| 7772 | jobType database.ProvisionerJobType, |
| 7773 | ) database.WorkspaceAgent { |
| 7774 | t.Helper() |
| 7775 | |
| 7776 | job := dbgen.ProvisionerJob(t, db, nil, database.ProvisionerJob{ |
| 7777 | Type: jobType, |
| 7778 | }) |
| 7779 | resource := dbgen.WorkspaceResource(t, db, database.WorkspaceResource{ |
| 7780 | JobID: job.ID, |
| 7781 | }) |
| 7782 | return dbgen.WorkspaceAgent(t, db, database.WorkspaceAgent{ |
| 7783 | Name: name, |
| 7784 | ResourceID: resource.ID, |
| 7785 | CreatedAt: createdAt, |
| 7786 | AuthInstanceID: sql.NullString{ |
| 7787 | String: authInstanceID, |
| 7788 | Valid: true, |
| 7789 | }, |
| 7790 | }) |
| 7791 | } |
| 7792 | |
| 7793 | func TestGetWorkspaceAgentsByInstanceID(t *testing.T) { |
| 7794 | t.Parallel() |
no test coverage detected