Skip to content

Commit

Permalink
Test: Wrap Loggly tests inside of it() functions
Browse files Browse the repository at this point in the history
  • Loading branch information
TomFrost committed Jun 20, 2014
1 parent d374e08 commit 4586c4f
Showing 1 changed file with 15 additions and 9 deletions.
24 changes: 15 additions & 9 deletions test/targets/loggly.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,20 @@
var should = require('should'),
logglyTarget = require('../../lib/targets/loggly');



describe("Loggly Target", function() {
(function(){
logglyTarget({token: 'Your-Token', username: 'Your-Username', password: 'Your-Password', subdomain: 'Your-subdomain'},'debug', new Date(), 'foo')
}).should.not.throw();

(function(){
logglyTarget({},'debug', new Date(), 'foo')
}).should.throw();
it('should successfully call the target', function() {
(function(){
logglyTarget({
token: 'Your-Token',
username: 'Your-Username',
password: 'Your-Password',
subdomain: 'Your-Subdomain'
}, 'debug', new Date(), 'foo');
}).should.not.throw();
});
it('should fail with missing options', function() {
(function(){
logglyTarget({},'debug', new Date(), 'foo')
}).should.throw();
});
});

0 comments on commit 4586c4f

Please sign in to comment.