// (C) 2007-2020 GoodData Corporation import { buildProject } from "../../builder"; import { schema } from "../../fixtures/dummySchema"; it("should build analytical dashboards", () => { expect(buildProject(schema).analyticalDashboards).toEqual([ { content: { filterContext: "/gdc/md/mockproject/obj/fd_fc", widgets: [ "/gdc/md/mockproject/obj/fd_fvw", "/gdc/md/mockproject/obj/fd_svw", "/gdc/md/mockproject/obj/fd_fkpi", "/gdc/md/mockproject/obj/fd_skpi", "/gdc/md/mockproject/obj/fd_skpi_date", "/gdc/md/mockproject/obj/fd_fvw_with_properties", ], }, meta: { category: "analyticalDashboard", identifier: "dash.a", uri: "/gdc/md/mockproject/obj/dash.a", title: "Dashboard A", }, }, { content: { filterContext: "/gdc/md/mockproject/obj/sd_fc", widgets: [ "/gdc/md/mockproject/obj/sd_fvw", "/gdc/md/mockproject/obj/sd_svw", "/gdc/md/mockproject/obj/sd_fkpi", "/gdc/md/mockproject/obj/overrides_title", ], }, meta: { category: "analyticalDashboard", identifier: "dash.dashboard_b", uri: "/gdc/md/mockproject/obj/dash.dashboard_b", title: "Dashboard B", }, }, { content: { dateFilterConfig: { filterName: "Date range", hideGranularities: ["GDC.time.date"], mode: "active", }, filterContext: "", widgets: ["/gdc/md/mockproject/obj/foo"], }, meta: { category: "analyticalDashboard", identifier: "dash.dashboard_c", uri: "/gdc/md/mockproject/obj/dash.dashboard_c", title: "Dashboard C", }, }, { content: { dateFilterConfig: { filterName: "Date range", hideGranularities: ["GDC.time.date"], mode: "active", }, filterContext: "", widgets: ["/gdc/md/mockproject/obj/foo_drill"], }, meta: { category: "analyticalDashboard", identifier: "dash.dashboard_d", uri: "/gdc/md/mockproject/obj/dash.dashboard_d", title: "Dashboard D", }, }, ]); });