We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f7b2840 commit b4266b1Copy full SHA for b4266b1
test/integration/message_test.ts
@@ -64,6 +64,19 @@ describe("HTTP transport", () => {
64
expect(HTTP.isEvent(message)).to.be.true;
65
});
66
67
+ it("Handles CloudEvents with datacontenttype of text/plain", () => {
68
+ const message: Message = HTTP.binary(
69
+ new CloudEvent({
70
+ source: "/test",
71
+ type: "example",
72
+ datacontenttype: "text/plain",
73
+ data: "Hello, friends!",
74
+ }),
75
+ );
76
+ const event = HTTP.toEvent(message);
77
+ expect(event.validate()).to.be.true;
78
+ });
79
+
80
it("Respects extension attribute casing (even if against spec)", () => {
81
// Now create a message that is an event
82
const message = {
0 commit comments