Security News
PyPI’s New Archival Feature Closes a Major Security Gap
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
@gooddata/reference-workspace
Advanced tools
This package is part of the GoodData.UI SDK. To learn more, go to the source monorepo.
This project defines a Logical Data Model (LDM) and test data recordings for use in various tests within the GoodData.UI SDK. The LDM and recordings are sourced from a live workspace in the GoodData Platform.
To create a reference workspace, set up the /reference-workspace-mgmt/.env
file and define variables using the template at /reference-workspace-mgmt/.env.template
.
After a successful import, the WORKSPACE_ID
will be automatically updated in the .env
file.
To create the workspace, run the import-ref-workspace
script using npm run import-ref-workspace
. All scripts are defined in the reference-workspace-mgmt
package.
The import process uses the @gooddata/fixtures
package.
Workspace metadata, such as dashboards and visualizations, are defined in /reference-workspace-mgmt/fixtures/tiger_metadata_extension.json
. This JSON file serves as the source of truth for the reference workspace.
After making changes in the live workspace, you need to export the workspace into the /reference-workspace-mgmt/fixtures/tiger_metadata_extension.json
file by running the npm run export-ref-workspace
command and committing the changes to Git.
All scripts are defined in the reference-workspace-mgmt
package.
Set the TIGER_API_TOKEN
, HOST_NAME
, and WORKSPACE_ID
in the /reference-workspace-mgmt/.env
file.
All recordings are defined in the reference-workspace/src/recordings
directory.
The standard GoodData catalog is defined in the src/md
directory. To update it, run the npm run refresh-md
command and build the refresh-md
package.
Workspace metadata, such as dashboards, catalogs, display forms, and visualization classes, are recorded in the /reference-workspace/src/recordings/metadata
directory.
To update the recording metadata:
src/recordings/metadata/catalog
directory and run the npm run refresh-recordings
script to record fresh data.dashboards.json
file and run npm run refresh-recordings
. To record a new dashboard, add an entry to dashboards.json
.displayForms.json
, list the display forms to be recorded. Each display form includes its definition and associated elements. If a display form contains many elements, you can set a limit, such as { "elementCount": 10 }.To update a recording, delete the directory named after the display form’s ID and run npm run refresh-recordings
. To record a new display form, add it to displayForms.json.visClasses
directory and run npm run refresh-recordings
.**NOTE:**Do not try to delete or update the empty hardcoded dashboard, as it does not exist in the reference workspace.
The src/recordings/uiTestScenarios
directory defines recordings for storybook scenarios (sdk-ui-tests). To update these recordings, follow these steps:
rush build
.npm run clear-recordings
.npm run populate-ref
(from the sdk-ui-tests directory).npm run refresh-recordings
.The Logical Data Model (LDM) is stored in the src/md directory and consists of two files:
full.ts: An auto-generated file created by running the npm run refresh-md
script.
Note: The script is hardcoded with an existing workspace. You may need to request access to this workspace or modify the script to use your own.
ext.ts: A file holding extensions to the standard LDM. This file stores custom LDM and analytical objects built on top of standard objects, such as PoP measures, Previous Period Measures, and Arithmetic Measures.
Note: Objects in
ext.ts
must be related to the reference workspace. Avoid using dummy or mock declarations.
Execution recordings are in the src/recordings/executions directory. Each execution recording must be stored in its own directory. The directories can be organized as needed.
Note: The
uiTestScenarios
directory is managed via automation. Do not store custom recordings here, as they will be overwritten.
Rules for recording entries:
defFingerprint
function).IExecutionDefinition
to JSON).scenarios.json
: Contains an array of { vis: string, scenario: string }
objects to create a Scenarios
mapping in the recording index.requests.json
: This specifies which data views to obtain and store. Examples are in the uiTestScenarios
directory.After creating this, run the npm run refresh-md
script to obtain data from the live reference workspace.
(C) 2017-2024 GoodData Corporation
This project is licensed under the MIT License. See LICENSE.
FAQs
GoodData SDK - Reference Workspace for tests
The npm package @gooddata/reference-workspace receives a total of 1,205 weekly downloads. As such, @gooddata/reference-workspace popularity was classified as popular.
We found that @gooddata/reference-workspace demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 45 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Research
Security News
Malicious npm package postcss-optimizer delivers BeaverTail malware, targeting developer systems; similarities to past campaigns suggest a North Korean connection.
Security News
CISA's KEV data is now on GitHub, offering easier access, API integration, commit history tracking, and automated updates for security teams and researchers.