You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+38-7Lines changed: 38 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -36,6 +36,7 @@ Javascript (NodeJS) is currently the implementation language/runtime with fulles
36
36
## Structure of a plugin
37
37
38
38
A plugin is a directory in this repo of the form `plugins/`_plugin-name_`/v1` containing certain key files:
39
+
39
40
-`metadata.json` - a file containing high-level information about the plugin (for example: the execution location of the plugin, or the information that appears in the Data Source Gallery, above).
40
41
-`ui.json` - a file describing the configuration that must be shown to a user who is in the process of adding the plugin to their tenant to connect with an instance of the back end system.
41
42
-`custom_types.json` (Optional) - a file containing information about non-standard object types that will be imported by the plugin into the Data Mesh.
@@ -46,40 +47,70 @@ A plugin is a directory in this repo of the form `plugins/`_plugin-name_`/v1` co
46
47
47
48
1.**Clone the Repository:**
48
49
First, clone the repository to your local machine:
| Install all packages |`pnpm i`| e.g. after merging main |
86
+
| Install all packages without changing the lockfile |`pnpm fast`| use `pnpm -w fast`if not in root |
87
+
| Install packages for certain package only |`pnpm -F "examplehybrid-v1" i`|`examplehybrid-v1` is from `package.json`'s name field |
88
+
| Install packages for certain package without changing the lockfile | `pnpm -F "examplehybrid-v1" i --frozen-lockfile` | `examplehybrid-v1` is from `package.json`'s name field |
89
+
| Add a package to Azure v1 |`pnpm add myPackage -F "azure-v1"`|`azure-v1` is from `package.json`'s name field |
90
+
91
+
6. **Testing the Plugin:** There are two main ways to test your plugin.
92
+
1. Using the SquaredUp Test/Validation Script (`validate.js` in `scripts\plugins-validator`):
93
+
70
94
```bash
71
-
npm ci
72
-
npm run validate
95
+
pnpm run -w validate
73
96
```
97
+
74
98
2. Using the SquaredUp Unit Test Framework which can be executed by running:
99
+
75
100
```bash
76
-
npm ci
101
+
# If running from the plugins directory
102
+
pnpm run unitTest
103
+
# If running from the root of the repo
77
104
# Replace 'ExamplePlugin' with your plugin name
78
-
npm test -- --pluginName="ExamplePlugin" --pluginPath="plugins/ExamplePlugin/v1"
105
+
pnpm run test -- --pluginName="ExamplePlugin" --pluginPath="plugins/ExamplePlugin/v1"
106
+
# OR
107
+
# Replace example-plugin-v1 with name from package.json of the plugin you are interested in
108
+
pnpm run -F "example-plugin-v1" unitTest
79
109
```
110
+
80
111
You should aim to do as much testing as possible with the `validate.js` script as the turn-around time is much quicker.
81
112
This process is described in more detail in [Testing a Plugin](docs/testingAPlugin.md).
82
-
6. **Installation**
113
+
7. **Installation**
83
114
The plugin is only installed when a Pull Request has been submitted. During PR creation you will be
84
115
asked for your Tenant (Organization) Name which can be retrieved from the [settings page](https://app.squaredup.com/settings/organization).
85
116
This will be used for restricting the plugin to the specified tenant only.
0 commit comments