mirror of
https://github.com/knex/knex.git
synced 2025-07-09 10:01:22 +00:00
23 lines
349 B
JavaScript
23 lines
349 B
JavaScript
/*global describe, it*/
|
|
|
|
'use strict';
|
|
|
|
module.exports = function(knex) {
|
|
|
|
describe('unions', function() {
|
|
|
|
it('handles unions', function() {
|
|
|
|
return knex('accounts')
|
|
.select('*')
|
|
.where('id', '=', 1)
|
|
.union(function() {
|
|
this.select('*').from('accounts').where('id', 2);
|
|
});
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|