forked from APIDevTools/json-schema-ref-parser
-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Context
The test bundle with no custom roots should track usage of $refs has been failing for sometime in the pipeline.
Current Behavior
Test is failing due to the objects not matching:
Actual:
{
"#/properties/bar": "http://localhost:9876/context.html#/properties/foo",
"#/properties/baz": "http://localhost:9876/context.html#/properties/foo/properties/id"
}
Expected:
{
"#/properties/bar": "http://localhost:9876/base/test//#/properties/foo",
"#/properties/baz": "http://localhost:9876/base/test//#/properties/foo/properties/id"
}
Seems like this is whats causing the issue - in a browser this returns the browser url, e.g. http://localhost:9876/context.html, not the source file directory :
json-schema-ref-parser/lib/index.js
Line 104 in 6e6ba8c
| args.path = url.resolve(url.cwd(), args.path); |
Expected Behavior
The actual should match the expected.
Possible Workaround/Solution
Test has been skipped: 446ca7a
Steps to Reproduce
I recommend changing the karma.conf.js to include only one browser to save time / headaches when testing locally.
browsers: {
chrome: host.ci ? host.os.linux : true,
firefox: false,
safari: false,
},
Remove skip from test
Run tests locally
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working