Skip to content

test: Add AppDIrectory tests#1787

Open
Roaders wants to merge 5 commits intomainfrom
test/1716-app-directory-tests
Open

test: Add AppDIrectory tests#1787
Roaders wants to merge 5 commits intomainfrom
test/1716-app-directory-tests

Conversation

@Roaders
Copy link
Contributor

@Roaders Roaders commented Mar 11, 2026

Duplicates #1720

This PR duplicates the above but pushed to the finos repo rather than from an external repo. As far as I am aware I can't edit the other PR and add commits to it. This rebases the changes onto main and runs the test in vitest rather than jest as we do for all tests now.

Summary

Converts the standalone app-directory specification test from \src/app-directory/specification/test/\ into a proper Jest test that runs as part of CI.

Changes

  • Added \ est/AppDirectory.test.ts\ with tests for:
    • Valid API name and version
    • \myApplication.json\ example validation against Application schema
    • \ dc3-workbench.json\ example validation against Application schema
  • Added @apidevtools/swagger-parser\ and \jsonschema\ to devDependencies
  • Removed \src/app-directory/specification/test/\ directory

Testing

Run the tests:
\\�ash
npm run test --workspace=@finos/fdc3-standard
\\

Closes #1716

adityashirsatrao007 and others added 5 commits March 11, 2026 15:55
Converts the standalone app-directory specification test into a proper
Jest test that runs as part of CI.

Changes:
- Added test/AppDirectory.test.ts with tests for:
  - Valid API name and version
  - myApplication.json example validation
  - fdc3-workbench.json example validation
- Added @apidevtools/swagger-parser and jsonschema to devDependencies
- Removed src/app-directory/specification/test/ directory

Closes #1716
@Roaders Roaders requested a review from a team as a code owner March 11, 2026 16:08
@netlify
Copy link

netlify bot commented Mar 11, 2026

Deploy Preview for fdc3 ready!

Name Link
🔨 Latest commit 9ccef58
🔍 Latest deploy log https://app.netlify.com/projects/fdc3/deploys/69b19371395d3c000848b4e1
😎 Deploy Preview https://deploy-preview-1787.preview-fdc3.finos.org
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions
Copy link

624 passed

@github-actions
Copy link

Coverage Report

Commit: 9ccef58
Base: main@6b7830d

Type Base This PR
Total Statements Coverage  95.54%  95.54% (+0%)
Total Branches Coverage  90.53%  90.53% (+0%)
Total Functions Coverage  96.86%  96.86% (+0%)
Total Lines Coverage  95.54%  95.54% (+0%)
Details (changed files)
FileStatementsBranchesFunctionsLines
Details (all files)
FileStatementsBranchesFunctionsLines
packages/fdc3-agent-proxy/src/DesktopAgentProxy.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/Messaging.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/index.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/apps/AppSupport.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/apps/DefaultAppSupport.ts 86.45% 77.77% 100% 86.45%
packages/fdc3-agent-proxy/src/channels/ChannelSupport.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/channels/DefaultChannel.ts 80% 100% 75% 80%
packages/fdc3-agent-proxy/src/channels/DefaultChannelSupport.ts 98.35% 94.64% 100% 98.35%
packages/fdc3-agent-proxy/src/channels/DefaultPrivateChannel.ts 98.93% 82.35% 100% 98.93%
packages/fdc3-agent-proxy/src/heartbeat/DefaultHeartbeatSupport.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/heartbeat/HeartbeatSupport.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/intents/DefaultIntentResolution.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/intents/DefaultIntentSupport.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/intents/IntentSupport.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/listeners/AbstractListener.ts 97.18% 62.5% 100% 97.18%
packages/fdc3-agent-proxy/src/listeners/DefaultContextListener.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/listeners/DefaultIntentListener.ts 100% 87.5% 100% 100%
packages/fdc3-agent-proxy/src/listeners/DesktopAgentEventListener.ts 89.85% 87.5% 100% 89.85%
packages/fdc3-agent-proxy/src/listeners/EventListener.ts 3.44% 0% 0% 3.44%
packages/fdc3-agent-proxy/src/listeners/HeartbeatListener.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/listeners/PrivateChannelEventListener.ts 95.89% 83.33% 100% 95.89%
packages/fdc3-agent-proxy/src/listeners/RegisterableListener.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/listeners/UserChannelContextListener.ts 100% 100% 100% 100%
packages/fdc3-agent-proxy/src/messaging/AbstractMessaging.ts 95% 100% 75% 95%
packages/fdc3-agent-proxy/src/util/AbstractFDC3Logger.ts 83.56% 69.23% 91.66% 83.56%
packages/fdc3-agent-proxy/src/util/Logger.ts 57.14% 50% 50% 57.14%
packages/fdc3-agent-proxy/src/util/throwIfUndefined.ts 100% 100% 100% 100%
packages/fdc3-get-agent/src/Fdc3Version.ts 0% 0% 0% 0%
packages/fdc3-get-agent/src/index.ts 100% 100% 100% 100%
packages/fdc3-get-agent/src/apps/NoopAppSupport.ts 0% 100% 100% 0%
packages/fdc3-get-agent/src/messaging/MessagePortMessaging.ts 100% 100% 100% 100%
packages/fdc3-get-agent/src/messaging/message-port.ts 98.27% 81.81% 100% 98.27%
packages/fdc3-get-agent/src/sessionStorage/DesktopAgentDetails.ts 96.87% 88.23% 100% 96.87%
packages/fdc3-get-agent/src/strategies/DesktopAgentPreloadLoader.ts 100% 80.95% 100% 100%
packages/fdc3-get-agent/src/strategies/FailoverHandler.ts 100% 81.81% 100% 100%
packages/fdc3-get-agent/src/strategies/HelloHandler.ts 87.27% 83.33% 100% 87.27%
packages/fdc3-get-agent/src/strategies/IdentityValidationHandler.ts 89.58% 73.33% 100% 89.58%
packages/fdc3-get-agent/src/strategies/Loader.ts 100% 100% 100% 100%
packages/fdc3-get-agent/src/strategies/PostMessageLoader.ts 98.3% 88% 100% 98.3%
packages/fdc3-get-agent/src/strategies/Timeouts.ts 100% 100% 100% 100%
packages/fdc3-get-agent/src/strategies/getAgent.ts 100% 100% 100% 100%
packages/fdc3-get-agent/src/ui/AbstractUIComponent.ts 91.04% 91.66% 100% 91.04%
packages/fdc3-get-agent/src/ui/DefaultDesktopAgentChannelSelector.ts 100% 88.88% 100% 100%
packages/fdc3-get-agent/src/ui/DefaultDesktopAgentIntentResolver.ts 100% 90% 100% 100%
packages/fdc3-get-agent/src/ui/NullChannelSelector.ts 100% 100% 100% 100%
packages/fdc3-get-agent/src/ui/NullIntentResolver.ts 100% 100% 66.66% 100%
packages/fdc3-get-agent/src/util/Logger.ts 62.5% 100% 50% 62.5%
packages/fdc3-get-agent/src/util/Uuid.ts 100% 100% 100% 100%
packages/fdc3-standard/src/index.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/AppIdentifier.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/AppIntent.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/AppMetadata.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/Channel.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/ContextMetadata.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/DesktopAgent.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/DesktopAgentIdentifier.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/DisplayMetadata.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/Errors.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/Events.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/GetAgent.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/Icon.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/Image.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/ImplementationMetadata.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/IntentMetadata.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/IntentResolution.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/Listener.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/Methods.ts 94.2% 85.18% 100% 94.2%
packages/fdc3-standard/src/api/PrivateChannel.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/RecommendedChannels.ts 100% 100% 100% 100%
packages/fdc3-standard/src/api/Types.ts 100% 100% 100% 100%
packages/fdc3-standard/src/context/ContextType.ts 100% 100% 100% 100%
packages/fdc3-standard/src/intents/Intents.ts 100% 100% 100% 100%
packages/fdc3-standard/src/internal/contextConfiguration.ts 100% 100% 100% 100%
packages/fdc3-standard/src/internal/intentConfiguration.ts 100% 100% 100% 100%
packages/fdc3-standard/src/internal/typeHelpers.ts 100% 100% 100% 100%
packages/fdc3-standard/src/ui/ChannelSelector.ts 100% 100% 100% 100%
packages/fdc3-standard/src/ui/Connectable.ts 100% 100% 100% 100%
packages/fdc3-standard/src/ui/IntentResolver.ts 100% 100% 100% 100%
toolbox/fdc3-for-web/fdc3-web-impl/src/BasicFDC3Server.ts 100% 100% 100% 100%
toolbox/fdc3-for-web/fdc3-web-impl/src/FDC3Server.ts 100% 100% 100% 100%
toolbox/fdc3-for-web/fdc3-web-impl/src/ServerContext.ts 100% 100% 100% 100%
toolbox/fdc3-for-web/fdc3-web-impl/src/index.ts 0% 0% 0% 0%
toolbox/fdc3-for-web/fdc3-web-impl/src/directory/BasicDirectory.ts 98.64% 90% 100% 98.64%
toolbox/fdc3-for-web/fdc3-web-impl/src/directory/DirectoryInterface.ts 100% 100% 100% 100%
toolbox/fdc3-for-web/fdc3-web-impl/src/handlers/BroadcastHandler.ts 98.14% 90% 100% 98.14%
toolbox/fdc3-for-web/fdc3-web-impl/src/handlers/HeartbeatHandler.ts 92.59% 87.87% 87.5% 92.59%
toolbox/fdc3-for-web/fdc3-web-impl/src/handlers/IntentHandler.ts 96.88% 95.48% 100% 96.88%
toolbox/fdc3-for-web/fdc3-web-impl/src/handlers/OpenHandler.ts 98.29% 92.3% 100% 98.29%
toolbox/fdc3-for-web/fdc3-web-impl/src/handlers/support.ts 100% 100% 100% 100%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Convert AppDirectory test application into a test

3 participants