from.test.js 991 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. var Test = require('../../support/test-runner');
  2. describe('Query Generation ::', function() {
  3. describe('FROM statements', function() {
  4. it('should generate a simple query with a FROM statement', function(done) {
  5. Test({
  6. query: {
  7. select: ['*'],
  8. from: 'books'
  9. },
  10. outcomes: [
  11. {
  12. dialect: 'postgresql',
  13. sql: 'select * from "books"',
  14. bindings: []
  15. },
  16. {
  17. dialect: 'mysql',
  18. sql: 'select * from `books`',
  19. bindings: []
  20. },
  21. {
  22. dialect: 'sqlite3',
  23. sql: 'select * from "books"',
  24. bindings: []
  25. },
  26. {
  27. dialect: 'oracle',
  28. sql: 'select * from "books"',
  29. bindings: []
  30. },
  31. {
  32. dialect: 'mariadb',
  33. sql: 'select * from `books`',
  34. bindings: []
  35. }
  36. ]
  37. }, done);
  38. });
  39. });
  40. });