You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

test.js 533B

1234567891011121314151617181920212223242526
  1. /**
  2. * Module dependencies.
  3. */
  4. var getUri = require('../');
  5. var assert = require('assert');
  6. describe('get-uri', function () {
  7. describe('bad input', function () {
  8. it('should throw a TypeError when callback function is given', function () {
  9. assert.throws(function () {
  10. getUri();
  11. }, TypeError);
  12. });
  13. it('should return a TypeError when no URI is given', function (done) {
  14. getUri(null, function (err) {
  15. assert.equal(err.name, 'TypeError');
  16. done();
  17. });
  18. });
  19. });
  20. });