Skip to content

Commit

Permalink
style: More lint style fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
notheotherben committed Mar 11, 2016
1 parent ea5d47b commit 0272ebe
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 16 deletions.
12 changes: 6 additions & 6 deletions dist/lib/Validators.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/lib/Validators.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions lib/Validators.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import MongoDB = require('mongodb');
import Skmatc = require('skmatc');
import MongoDB = require("mongodb");
import Skmatc = require("skmatc");

export function DefaultValidators() {
return [
Skmatc.create(schema => schema === MongoDB.ObjectID, function(schema, data) {
return this.assert(!data || data instanceof MongoDB.ObjectID || (data._bsontype === 'ObjectID' && data.id), "Expected " + JSON.stringify(data) + " to be a valid MongoDB.ObjectID object");
}, { name: 'ObjectID validation' }),
return this.assert(!data || data instanceof MongoDB.ObjectID || (data._bsontype === "ObjectID" && data.id), "Expected " + JSON.stringify(data) + " to be a valid MongoDB.ObjectID object");
}, { name: "ObjectID validation" }),
Skmatc.create(schema => schema === Buffer, function(schema, data) {
return this.assert(data && (data instanceof MongoDB.Binary || (data._bsontype === 'Binary' && data.buffer)), "Expected " + JSON.stringify(data) + " to be a valid MongoDB.Binary object");
}, { name: 'Buffer validation' })
return this.assert(data && (data instanceof MongoDB.Binary || (data._bsontype === "Binary" && data.buffer)), "Expected " + JSON.stringify(data) + " to be a valid MongoDB.Binary object");
}, { name: "Buffer validation" })
];
}
4 changes: 2 additions & 2 deletions test/Cache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ describe("Cache",() => {
});

it("should generate a key based on the object's ID",() => {
chai.expect(director.buildKey({ _id: "test' })).to.be.equal('test");
chai.expect(director.buildKey({ _id: "test" })).to.be.equal("test");
});

it("should only report that queries which specify the _id field are usable",() => {
Expand All @@ -86,7 +86,7 @@ describe("Cache",() => {
});

it("should generate a key based on the query ID",() => {
chai.expect(director.buildQueryKey({ _id: "test' })).to.be.equal('test");
chai.expect(director.buildQueryKey({ _id: "test" })).to.be.equal("test");
});
});

Expand Down
2 changes: 1 addition & 1 deletion test/Core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ describe("Core",() => {
});

it("should throw an error if no URI or configuration object was provided",() => {
chai.expect(() => new Iridium.Core('')).to.throw("Expected either a URI or config object to be supplied when initializing Iridium");
chai.expect(() => new Iridium.Core("")).to.throw("Expected either a URI or config object to be supplied when initializing Iridium");
});

describe("should correctly convert the configuration object into a URI string", () => {
Expand Down

0 comments on commit 0272ebe

Please sign in to comment.