Skip to content

Commit 1118619

Browse files
committed
test(document): Add test for direct share of document with custom ID
1 parent 83fa4f8 commit 1118619

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
resource "dynatrace_iam_group" "this" {
2+
name = "#name#"
3+
}
4+
5+
resource "dynatrace_document" "this" {
6+
custom_id = "#name#"
7+
type = "dashboard"
8+
name = "#name#"
9+
content = jsonencode(
10+
{
11+
"version" : 1,
12+
"variables" : [],
13+
"tiles" : {
14+
"0" : {
15+
"type" : "markdown",
16+
"title" : "",
17+
"content" : "Dashboard content"
18+
}
19+
},
20+
"layouts" : {
21+
"0" : {
22+
"x" : 0,
23+
"y" : 0,
24+
"w" : 24,
25+
"h" : 14
26+
}
27+
}
28+
}
29+
)
30+
}
31+
32+
resource "dynatrace_direct_shares" "this" {
33+
document_id = dynatrace_document.this.id
34+
access = "read"
35+
36+
recipients {
37+
recipient {
38+
id = dynatrace_iam_group.this.id
39+
type = "group"
40+
}
41+
}
42+
}

0 commit comments

Comments
 (0)