Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3633dfc

Browse files
committed
Make mock entities reference each other
1 parent fd0407f commit 3633dfc

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

site/src/test_helpers/entities.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -11,33 +11,33 @@ export const MockUser: UserResponse = {
1111
created_at: "",
1212
}
1313

14-
export const MockProject: Project = {
15-
id: "test-project",
14+
export const MockOrganization: Organization = {
15+
id: "test-org",
16+
name: "Test Organization",
1617
created_at: "",
1718
updated_at: "",
18-
organization_id: "test-org",
19-
name: "Test Project",
20-
provisioner: "test-provisioner",
21-
active_version_id: "",
2219
}
2320

2421
export const MockProvisioner: Provisioner = {
2522
id: "test-provisioner",
2623
name: "Test Provisioner",
2724
}
2825

29-
export const MockOrganization: Organization = {
30-
id: "test-org",
31-
name: "Test Organization",
26+
export const MockProject: Project = {
27+
id: "test-project",
3228
created_at: "",
3329
updated_at: "",
30+
organization_id: MockOrganization.id,
31+
name: "Test Project",
32+
provisioner: MockProvisioner.id,
33+
active_version_id: "",
3434
}
3535

3636
export const MockWorkspace: Workspace = {
3737
id: "test-workspace",
3838
name: "Test-Workspace",
3939
created_at: "",
4040
updated_at: "",
41-
project_id: "test-project",
42-
owner_id: "test-user",
41+
project_id: MockProject.id,
42+
owner_id: MockUser.id
4343
}

0 commit comments

Comments
 (0)