Skip to content

Commit

Permalink
fix: bumped minimaltempalte's generator version
Browse files Browse the repository at this point in the history
  • Loading branch information
Souvikns committed Dec 29, 2024
1 parent a5b13fc commit dda617e
Show file tree
Hide file tree
Showing 5 changed files with 107 additions and 32 deletions.
73 changes: 73 additions & 0 deletions github-action/test/unoptimized_optimized.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
asyncapi: 2.0.0
info:
title: Streetlights API
version: 1.0.0
channels:
smartylighting/event/{streetlightId}/lighting/measured:
$ref: >-
#/components/channels/smartylighting/event/{streetlightId}/lighting/measured
parameters:
streetlightId:
schema:
$ref: '#/components/schemas/schema'
smartylighting/action/{streetlightId}/turn/on:
$ref: '#/components/channels/smartylighting/action/{streetlightId}/turn/on'
components:
schemas:
sentAt:
type: string
format: date-time
lumens:
type: integer
minimum: 0
payload:
type: object
properties:
sentAt:
$ref: '#/components/schemas/sentAt'
messages:
message:
name: turnOnOff
title: Turn on/off
traits:
- headers:
type: object
properties:
my-app-header:
type: integer
minimum: 0
maximum: 100
payload:
$ref: '#/components/schemas/payload'
operations:
subscribe:
operationId: receiveLightMeasurement
traits:
- bindings:
kafka:
clientId: my-app-id
message:
$ref: '#/components/messages/message'
publish:
operationId: turnOn
traits:
- bindings:
kafka:
clientId: my-app-id
message:
$ref: '#/components/messages/message'
channels:
smartylighting/event/{streetlightId}/lighting/measured:
parameters:
streetlightId:
schema:
$ref: '#/components/schemas/schema'
subscribe:
$ref: '#/components/operations/subscribe'
smartylighting/action/{streetlightId}/turn/on:
parameters:
streetlightId:
schema:
$ref: '#/components/schemas/schema'
publish:
$ref: '#/components/operations/publish'
3 changes: 3 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

59 changes: 29 additions & 30 deletions test/fixtures/badFormatAsyncapi.json
Original file line number Diff line number Diff line change
@@ -1,38 +1,37 @@
{
"asyncapi": "2.2.0",
"info": {
"title": "Account Service",
"version": "1.0.0",
"description":
"This service is in charge of processing user signups"
},
"channels": {
"user/signedup": {
"subscribe": {
"message": {
"$ref": "#/components/messages/UserSignedUp"
}
"asyncapi": "2.2.0",
"info": {
"title": "Account Service",
"version": "1.0.0",
"description": "This service is in charge of processing user signups"
},
"channels": {
"user/signedup": {
"subscribe": {
"message": {
"$ref": "#/components/messages/UserSignedUp"
}
}
},
"components": {
"messages": {
"UserSignedUp": {
"payload": {
"type": "object",
"properties": {
"displayName": {
"type": "string",
"description": "Name of the user"
},
"email": {
"type": "string",
"format": "email",
"description": "Email of the user"
}
}
},
"components": {
"messages": {
"UserSignedUp": {
"payload": {
"type": "object",
"properties": {
"displayName": {
"type": "string",
"description": "Name of the user"
},
"email": {
"type": "string",
"format": "email",
"description": "Email of the user"
}
}
}
}
}
}
}
}
2 changes: 1 addition & 1 deletion test/fixtures/newtemplate/__transpiled/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion test/fixtures/newtemplate/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"generator": {
"renderer": "react",
"apiVersion": "v3",
"generator": ">=2.0.0 <=2.4.1",
"generator": ">=2.0.0 <=2.5.0",
"parameters": {
"version": {
"description": "Custom version to be used"
Expand Down

0 comments on commit dda617e

Please sign in to comment.