diff --git a/README.md b/README.md index 6cb337e6..8d582a87 100644 --- a/README.md +++ b/README.md @@ -121,7 +121,7 @@ const v1 = require("cloudevents-sdk/v1"); */ let myevent = v1.event() .type("com.github.pull.create") - .source("urn:event:from:myapi/resourse/123"); + .source("urn:event:from:myapi/resource/123"); ``` #### Formatting @@ -134,7 +134,7 @@ const v1 = require("cloudevents-sdk/v1"); */ let myevent = v1.event() .type("com.github.pull.create") - .source("urn:event:from:myapi/resourse/123"); + .source("urn:event:from:myapi/resource/123"); /* * Format the payload and return it @@ -152,7 +152,7 @@ const v1 = require("cloudevents-sdk/v1"); */ let myevent = v1.event() .type("com.github.pull.create") - .source("urn:event:from:myapi/resourse/123"); + .source("urn:event:from:myapi/resource/123"); // The binding configuration using POST let config = { diff --git a/test/bindings/http/receiver_binary_1_tests.js b/test/bindings/http/receiver_binary_1_tests.js index 9116bace..6d778150 100644 --- a/test/bindings/http/receiver_binary_1_tests.js +++ b/test/bindings/http/receiver_binary_1_tests.js @@ -430,7 +430,7 @@ describe("HTTP Transport Binding Binary Receiver for CloudEvents v1.0", () => { it("Should accept 'extension1'", () => { // setup - const extension1 = "mycuston-ext1"; + const extension1 = "mycustom-ext1"; const payload = { data: "dataString" }; diff --git a/test/bindings/http/receiver_structured_1_test.js b/test/bindings/http/receiver_structured_1_test.js index 313d5c11..caee580e 100644 --- a/test/bindings/http/receiver_structured_1_test.js +++ b/test/bindings/http/receiver_structured_1_test.js @@ -10,7 +10,7 @@ const HTTPStructuredReceiver = const receiver = new HTTPStructuredReceiver(); const type = "com.github.pull.create"; -const source = "urn:event:from:myapi/resourse/123"; +const source = "urn:event:from:myapi/resource/123"; const now = new Date(); const dataschema = "http://cloudevents.io/schema.json"; @@ -130,7 +130,7 @@ describe("HTTP Transport Binding Structured Receiver for CloudEvents v1.0", it("Should accept 'extension1'", () => { // setup - const extension1 = "mycuston-ext1"; + const extension1 = "mycustom-ext1"; const payload = v1.event() .type(type) .source(source) @@ -154,7 +154,7 @@ describe("HTTP Transport Binding Structured Receiver for CloudEvents v1.0", .to.equal(extension1); }); - it("Should parse 'data' stringfied json to json object", () => { + it("Should parse 'data' stringified json to json object", () => { // setup const payload = v1.event() .type(type) diff --git a/test/http_binding_1.js b/test/http_binding_1.js index 8725c3e4..300c908c 100644 --- a/test/http_binding_1.js +++ b/test/http_binding_1.js @@ -11,7 +11,7 @@ const { } = require("../v1/index.js"); const type = "com.github.pull.create"; -const source = "urn:event:from:myapi/resourse/123"; +const source = "urn:event:from:myapi/resource/123"; const contentType = "application/cloudevents+json; charset=utf-8"; const now = new Date(); const dataschema = "http://cloudevents.io/schema.json"; diff --git a/test/spec_1_tests.js b/test/spec_1_tests.js index 25344b1c..71ace864 100644 --- a/test/spec_1_tests.js +++ b/test/spec_1_tests.js @@ -6,7 +6,7 @@ const { asBase64 } = require("../lib/utils/fun.js"); const id = uuidv4(); const type = "com.github.pull.create"; -const source = "urn:event:from:myapi/resourse/123"; +const source = "urn:event:from:myapi/resource/123"; const time = new Date(); const dataschema = "http://example.com/registry/myschema.json"; const dataContentType = "application/json"; @@ -63,7 +63,7 @@ describe("CloudEvents Spec v1.0", () => { }); }); - describe("Extenstions Constraints", () => { + describe("Extensions Constraints", () => { it("should be ok when type is 'boolean'", () => { cloudevent.addExtension("ext-boolean", true); expect(cloudevent.spec.payload["ext-boolean"]) @@ -126,7 +126,7 @@ describe("CloudEvents Spec v1.0", () => { cloudevent.spec.payload.id = id; }); - it("should throw an erro when is empty", () => { + it("should throw an error when is empty", () => { cloudevent.spec.payload.id = ""; expect(cloudevent.format.bind(cloudevent)) .to