Skip to content
Snippets Groups Projects
Unverified Commit 4fe4c52f authored by Cam Saul's avatar Cam Saul
Browse files

Test Fixes :wrench:

parent 4fcb8fd9
No related merge requests found
......@@ -82,14 +82,9 @@
[fields]
(let [table-id->name-field (fields->table-id->name-field (pk-fields fields))]
(for [field fields]
(-> field
;; add matching `:name_field` if it's a PK
(assoc :name_field (when (isa? (:special_type field) :type/PK)
(-> (table-id->name-field (:table_id field))
;; remove :table_id for these Fields since it's not needed for frontend
(dissoc :table_id))))
;; now remove `:table_id` since we don't need it for frontend widgets, only for this function here
(dissoc :table_id)))))
;; add matching `:name_field` if it's a PK
(assoc field :name_field (when (isa? (:special_type field) :type/PK)
(table-id->name-field (:table_id field)))))))
;; We hydrate the `:human_readable_field` for each Dimension using the usual hydration logic, so it contains columns we
......
......@@ -93,10 +93,11 @@
:visualization_settings {}
:dataset_query {:type "query"}
:parameters ()
:param_values nil})
:param_values nil
:param_fields nil})
(def successful-dashboard-info
{:description nil, :parameters (), :ordered_cards (), :param_values nil})
{:description nil, :parameters (), :ordered_cards (), :param_values nil, :param_fields nil})
;;; ------------------------------------------- GET /api/embed/card/:token -------------------------------------------
......
......@@ -83,7 +83,9 @@
:base_type "type/Text"
:has_field_values "list"
:fk_target_field_id nil
:parent_id nil})
:parent_id nil
:dimensions []
:name_field nil})
((user->client :rasta) :get 200 (format "field/%d" (id :users :name))))
......
......@@ -88,7 +88,7 @@
;; Check that we can fetch a PublicCard
(expect
#{:dataset_query :description :display :id :name :visualization_settings :param_values}
#{:dataset_query :description :display :id :name :visualization_settings :param_values :param_fields}
(tu/with-temporary-setting-values [enable-public-sharing true]
(with-temp-public-card [{uuid :public_uuid}]
(set (keys (http/client :get 200 (str "public/card/" uuid)))))))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment