Skip to content

Validation is broken #500

Closed
Closed
@adgerrits

Description

@adgerrits

Describe the Bug
Event.validate() is not functioning correct (tested in the express-ex example)

Steps to Reproduce

  1. let e = HTTP.toEvent({headers: req.headers,body: { "a space": "not allowed", specversion: "1.0", source: "source1", id: "1", type: "test" }
  2. e.validate() //no error

Expected Behavior
An error (just like when an ext.attribute with the name "Acapital" is used).

Additional context
The problem seems to lie in spec.ts because of a broken reference tot the v1-schema. Looks as if it's there since release 5.4.0 when a separate schema-folder was created.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type/bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions