summaryrefslogtreecommitdiffstats
path: root/cmd/binapi-generator/generator_test.go
diff options
context:
space:
mode:
authorRastislav Szabo <raszabo@cisco.com>2017-09-25 21:24:21 +0200
committerRastislav Szabo <raszabo@cisco.com>2017-09-25 21:24:21 +0200
commit70ae7c10259161994e49bae8d095dcce840dfed4 (patch)
tree52ec23e70a5e3b7b679447004497ffa6063e211e /cmd/binapi-generator/generator_test.go
parent03bc1c23595e998e8fa75a65e23bedfbec115643 (diff)
generator fix - better identification of message types
Change-Id: I00dbd57acba706b4a842e2b6c6df2d7b7ab7c37a Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
Diffstat (limited to 'cmd/binapi-generator/generator_test.go')
-rw-r--r--cmd/binapi-generator/generator_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd/binapi-generator/generator_test.go b/cmd/binapi-generator/generator_test.go
index 7527a98..c7d89ce 100644
--- a/cmd/binapi-generator/generator_test.go
+++ b/cmd/binapi-generator/generator_test.go
@@ -245,7 +245,7 @@ func TestGenerateMessageFieldTypes(t *testing.T) {
for j := 0; j < types.At(i).Len(); j++ {
field := types.At(i).At(j)
if jsongo.TypeArray == field.GetType() {
- err := processMessageField(testCtx, &fields, field)
+ err := processMessageField(testCtx, &fields, field, otherMessage)
Expect(err).ShouldNot(HaveOccurred())
Expect(fields[j-1]).To(BeEquivalentTo(expectedTypes[j-1]))
}
@@ -282,7 +282,7 @@ func TestGenerateMessageFieldMessages(t *testing.T) {
specificFieldName == "client_index" || specificFieldName == "context" {
continue
}
- err := processMessageField(testCtx, &fields, field)
+ err := processMessageField(testCtx, &fields, field, requestMessage)
Expect(err).ShouldNot(HaveOccurred())
Expect(fields[customIndex]).To(BeEquivalentTo(expectedTypes[customIndex]))
customIndex++