Clean up regexop tests
This commit is contained in:
parent
0f63e7a72e
commit
a1d78229f5
|
@ -653,7 +653,8 @@ describe('mysql', function () {
|
||||||
});
|
});
|
||||||
it('should print a warning when the ignore flag is set',
|
it('should print a warning when the ignore flag is set',
|
||||||
function(done) {
|
function(done) {
|
||||||
Post.find({where: {content: {regexp: new RegExp(/^a/i)}}}, function(err, posts) {
|
Post.find({where: {content: {regexp: new RegExp(/^a/i)}}},
|
||||||
|
function(err, posts) {
|
||||||
console.warn.calledOnce.should.be.ok;
|
console.warn.calledOnce.should.be.ok;
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
|
@ -661,7 +662,8 @@ describe('mysql', function () {
|
||||||
|
|
||||||
it('should print a warning when the global flag is set',
|
it('should print a warning when the global flag is set',
|
||||||
function(done) {
|
function(done) {
|
||||||
Post.find({where: {content: {regexp: new RegExp(/^a/g)}}}, function(err, posts) {
|
Post.find({where: {content: {regexp: new RegExp(/^a/g)}}},
|
||||||
|
function(err, posts) {
|
||||||
console.warn.calledOnce.should.be.ok;
|
console.warn.calledOnce.should.be.ok;
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
|
@ -669,7 +671,8 @@ describe('mysql', function () {
|
||||||
|
|
||||||
it('should print a warning when the multiline flag is set',
|
it('should print a warning when the multiline flag is set',
|
||||||
function(done) {
|
function(done) {
|
||||||
Post.find({where: {content: {regexp: new RegExp(/^a/m)}}}, function(err, posts) {
|
Post.find({where: {content: {regexp: new RegExp(/^a/m)}}},
|
||||||
|
function(err, posts) {
|
||||||
console.warn.calledOnce.should.be.ok;
|
console.warn.calledOnce.should.be.ok;
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue