Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unit test failure on "empty object should be valid sometimes" #38

Open
acthp opened this issue May 16, 2015 · 1 comment · May be fixed by #40
Open

unit test failure on "empty object should be valid sometimes" #38

acthp opened this issue May 16, 2015 · 1 comment · May be fixed by #40

Comments

@acthp
Copy link

acthp commented May 16, 2015

Just tried running the unit tests on master branch, but it failed in validate-object.

@vedmalex
Copy link

vedmalex commented Jun 1, 2015

+1

yes it break the my code after update... to latest version

var schema = require('js-schema');
var assert = require('assert');
v = schema({
    out: String,
    rest: [null, String]
});

var val = {
    out: "sometext"
};

console.log(v.errors(val)) //<< it is invalid.
assert(v(val)); // << false

vedmalex added a commit to vedmalex/js-schema that referenced this issue Jun 1, 2015
not equivalent rafactoring of code. fixes issue with empty object validataion
@vedmalex vedmalex linked a pull request Jun 1, 2015 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants