Skip to content

Commit

Permalink
W-15520216 - Fix asyncApi-2.x-all examples
Browse files Browse the repository at this point in the history
  • Loading branch information
looseale committed Apr 18, 2024
1 parent 96891b5 commit ab21289
Show file tree
Hide file tree
Showing 7 changed files with 67 additions and 46 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,17 @@ channels:
some-channel:
bindings:
ibmmq:
destinationType: test
destinationType: queue
queue:
objectName: test
isPartitioned: true
exclusive: false
maxMsgLength: 123
bindingVersion: test
some-other-channel:
bindings:
ibmmq:
destinationType: topic
topic:
string: test
objectName: test
Expand All @@ -59,7 +65,7 @@ channels:
message:
bindings:
ibmmq:
type: test
type: binary
description: test
expiry: 123
bindingVersion: test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,26 +40,31 @@ channels:
some-channel:
bindings:
ibmmq:
destinationType: test
destinationType: queue
queue:
objectName: test
isPartitioned: true
exclusive: false
maxMsgLength: 123
bindingVersion: test
some-other-channel:
bindings:
ibmmq:
destinationType: topic
topic:
string: test
objectName: test
durablePermitted: true
lastMsgRetained: false
maxMsgLength: 123
bindingVersion: test
description: some channel
publish:
bindings:
ibmmq: {}
message:
bindings:
ibmmq:
type: test
type: binary
description: test
expiry: 123
bindingVersion: test
Expand All @@ -70,7 +75,7 @@ channels:
bindings:
anypointmq:
destination: test
destinationType: test
destinationType: exchange
bindingVersion: 0.1.0
description: some channel
publish:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,37 +40,33 @@ channels:
second-channel:
bindings:
ibmmq:
destinationType: test
queue:
objectName: test
isPartitioned: true
exclusive: false
destinationType: topic
topic:
string: test
objectName: test
durablePermitted: true
lastMsgRetained: false
maxMsgLength: 123
bindingVersion: test
description: some channel
publish:
bindings:
ibmmq: {}
ibmmq: { }
message:
bindings:
ibmmq:
type: test
type: binary
description: test
expiry: 123
bindingVersion: test
headers: test1, test2, test3
payload:
type: string
description: some channel
third-channel:
bindings:
anypointmq:
destination: test
destinationType: test
destinationType: exchange
bindingVersion: 0.1.0
description: some channel
publish:
Expand All @@ -97,7 +93,7 @@ channels:
destinationType: queue
queue:
name: CreatedHREvents
accessType: test
accessType: exclusive
maxMsgSpoolSize: test
maxTtl: test
topicSubscriptions:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,37 +65,33 @@ channels:
second-channel:
bindings:
ibmmq:
destinationType: test
queue:
objectName: test
isPartitioned: true
exclusive: false
destinationType: topic
topic:
string: test
objectName: test
durablePermitted: true
lastMsgRetained: false
maxMsgLength: 123
bindingVersion: test
description: some channel
publish:
bindings:
ibmmq: {}
ibmmq: { }
message:
bindings:
ibmmq:
type: test
type: binary
description: test
expiry: 123
bindingVersion: test
headers: test1, test2, test3
payload:
type: string
description: some channel
third-channel:
bindings:
anypointmq:
destination: test
destinationType: test
destinationType: exchange
bindingVersion: 0.1.0
description: some channel
publish:
Expand All @@ -122,7 +118,7 @@ channels:
destinationType: queue
queue:
name: CreatedHREvents
accessType: test
accessType: exclusive
maxMsgSpoolSize: test
maxTtl: test
topicSubscriptions:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,37 +65,33 @@ channels:
second-channel:
bindings:
ibmmq:
destinationType: test
queue:
objectName: test
isPartitioned: true
exclusive: false
destinationType: topic
topic:
string: test
objectName: test
durablePermitted: true
lastMsgRetained: false
maxMsgLength: 123
bindingVersion: test
description: some channel
publish:
bindings:
ibmmq: {}
ibmmq: { }
message:
bindings:
ibmmq:
type: test
type: binary
description: test
expiry: 123
bindingVersion: test
headers: test1, test2, test3
payload:
type: string
description: some channel
third-channel:
bindings:
anypointmq:
destination: test
destinationType: test
destinationType: exchange
bindingVersion: 0.1.0
description: some channel
publish:
Expand All @@ -122,7 +118,7 @@ channels:
destinationType: queue
queue:
name: CreatedHREvents
accessType: test
accessType: exclusive
maxMsgSpoolSize: test
maxTtl: test
topicSubscriptions:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,37 +72,33 @@ channels:
second-channel:
bindings:
ibmmq:
destinationType: test
queue:
objectName: test
isPartitioned: true
exclusive: false
destinationType: topic
topic:
string: test
objectName: test
durablePermitted: true
lastMsgRetained: false
maxMsgLength: 123
bindingVersion: test
description: some channel
publish:
bindings:
ibmmq: {}
ibmmq: { }
message:
bindings:
ibmmq:
type: test
type: binary
description: test
expiry: 123
bindingVersion: test
headers: test1, test2, test3
payload:
type: string
description: some channel
third-channel:
bindings:
anypointmq:
destination: test
destinationType: test
destinationType: exchange
bindingVersion: 0.1.0
description: some channel
publish:
Expand All @@ -129,7 +125,7 @@ channels:
destinationType: queue
queue:
name: CreatedHREvents
accessType: test
accessType: exclusive
maxMsgSpoolSize: test
maxTtl: test
topicSubscriptions:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ class Async20UniquePlatformUnitValidationsTest extends UniquePlatformReportGenTe
val asyncPath: String = "file://amf-cli/shared/src/test/resources/validations/async20/"
override val basePath: String = asyncPath + "validations/"
override val reportsPath: String = "amf-cli/shared/src/test/resources/validations/reports/async20/"
private val cyclePath: String = "file://amf-cli/shared/src/test/resources/upanddown/cycle/async20/"

test("Required channel object") {
validate("required-channels.yaml", Some("required-channels.report"))
Expand Down Expand Up @@ -435,4 +436,29 @@ class Async20UniquePlatformUnitValidationsTest extends UniquePlatformReportGenTe
test("Async Amqp operation binding version 0.3.0") {
validate("amqp-operation-binding-030.yaml", Some("amqp-operation-binding-030.report"))
}

test("Async asyncApi-2.1-all should be valid") {
validate(api = "asyncApi-2.1-all.yaml", directory = cyclePath)
}

test("Async asyncApi-2.2-all should be valid") {
validate(api = "asyncApi-2.2-all.yaml", directory = cyclePath)
}

test("Async asyncApi-2.3-all should be valid") {
validate(api = "asyncApi-2.3-all.yaml", directory = cyclePath)
}

test("Async asyncApi-2.4-all should be valid") {
validate(api = "asyncApi-2.4-all.yaml", directory = cyclePath)
}

test("Async asyncApi-2.5-all should be valid") {
validate(api = "asyncApi-2.5-all.yaml", directory = cyclePath)
}

test("Async asyncApi-2.6-all should be valid") {
validate(api = "asyncApi-2.6-all.yaml", directory = cyclePath)
}

}

0 comments on commit ab21289

Please sign in to comment.