Skip to content

Commit 7a6845a

Browse files
committed
chore: tests clean up
There were some behaviour changes. This commit adapts these changes. JIRA: TRIVIAL risk: low
1 parent 31f86a9 commit 7a6845a

File tree

29 files changed

+862
-555
lines changed

29 files changed

+862
-555
lines changed

gooddata-sdk/gooddata_sdk/catalog/workspace/declarative_model/workspace/logical_model/dataset/dataset.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
from typing import Optional
66

77
import attr
8+
import attrs
89
from gooddata_api_client.model.data_source_table_identifier import DataSourceTableIdentifier
910
from gooddata_api_client.model.declarative_aggregated_fact import DeclarativeAggregatedFact
1011
from gooddata_api_client.model.declarative_attribute import DeclarativeAttribute
@@ -41,7 +42,7 @@ class CatalogDeclarativeDataset(Base):
4142
description: Optional[str] = None
4243
attributes: Optional[list[CatalogDeclarativeAttribute]] = None
4344
facts: Optional[list[CatalogDeclarativeFact]] = None
44-
aggregated_facts: Optional[list[CatalogDeclarativeAggregatedFact]] = None
45+
aggregated_facts: Optional[list[CatalogDeclarativeAggregatedFact]] = attrs.field(factory=list)
4546
data_source_table_id: Optional[CatalogDataSourceTableIdentifier] = None
4647
sql: Optional[CatalogDeclarativeDatasetSql] = None
4748
tags: Optional[list[str]] = None

gooddata-sdk/tests/catalog/expected/declarative_data_sources.json

Lines changed: 1 addition & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -21,67 +21,8 @@
2121
],
2222
"schema": "demo",
2323
"type": "POSTGRESQL",
24-
"url": "jdbc:postgresql://localhost:5432/demo",
24+
"url": "jdbc:postgresql://localhost:5432/demo?sslmode=prefer",
2525
"username": "demouser"
26-
},
27-
{
28-
"id": "demo-test-ds-databricks-client-secret",
29-
"name": "demo-test-ds-databricks-client-secret",
30-
"permissions": [
31-
{
32-
"assignee": {
33-
"id": "demo2",
34-
"type": "user"
35-
},
36-
"name": "MANAGE"
37-
},
38-
{
39-
"assignee": {
40-
"id": "demoGroup",
41-
"type": "userGroup"
42-
},
43-
"name": "USE"
44-
}
45-
],
46-
"schema": "demo",
47-
"type": "DATABRICKS",
48-
"url": "jdbc:databricks://dbc-1234-abc.cloud.databricks.com:443;httpPath=/sql/1.0/warehouses/9876fdsa;",
49-
"clientId": "client-id",
50-
"parameters": [
51-
{
52-
"name": "catalog",
53-
"value": "demo"
54-
}
55-
]
56-
},
57-
{
58-
"id": "demo-test-ds-databricks-token",
59-
"name": "demo-test-ds-databricks-token",
60-
"permissions": [
61-
{
62-
"assignee": {
63-
"id": "demo2",
64-
"type": "user"
65-
},
66-
"name": "MANAGE"
67-
},
68-
{
69-
"assignee": {
70-
"id": "demoGroup",
71-
"type": "userGroup"
72-
},
73-
"name": "USE"
74-
}
75-
],
76-
"schema": "demo",
77-
"type": "DATABRICKS",
78-
"url": "jdbc:databricks://dbc-1234-abc.cloud.databricks.com:443;httpPath=/sql/1.0/warehouses/9876fdsa;",
79-
"parameters": [
80-
{
81-
"name": "catalog",
82-
"value": "demo"
83-
}
84-
]
8526
}
8627
]
8728
}

0 commit comments

Comments
 (0)