Skip to content
This repository was archived by the owner on Oct 21, 2020. It is now read-only.

Commit

Permalink
Switched to implement.js for interface assertions
Browse files Browse the repository at this point in the history
So, we can remove our own `implements` assertion.
  • Loading branch information
micha149 committed Aug 12, 2014
1 parent 0ae175d commit e3d6f7c
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 89 deletions.
3 changes: 1 addition & 2 deletions homelib.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,5 @@ module.exports = {
Message: require(path + 'Message'),
Module: require(path + 'Module'),
Connection: require(path + 'Connection'),
Timer: require(path + 'Timer'),
assert: require(path + "assert")
Timer: require(path + 'Timer')
};
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
},
"dependencies": {
"async": "~0.8.0",
"implementjs": "~0.3.0",
"suncalc": "~1.4.0",
"underscore": "~1.6.0"
},
Expand Down
6 changes: 3 additions & 3 deletions src/Connection.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
var Driver = require('./Driver/DriverInterface'),
Message = require('./Message'),
invoke = require('underscore').invoke,
assert = require('./assert');
impl = require('implementjs'),
invoke = require('underscore').invoke;

/**
* The connection object represents an interface to the knx
Expand All @@ -16,7 +16,7 @@ function Connection(driver) {

var self = this;

assert.implements(driver, Driver);
impl.implements(driver, Driver);

this._driver = driver;
this._listeners = {};
Expand Down
20 changes: 0 additions & 20 deletions src/assert.js

This file was deleted.

2 changes: 1 addition & 1 deletion test/Driver/KnxIpDriverTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ var Buffer = require('buffer').Buffer,
chai = require('chai'),
assert = chai.assert,
expect = chai.expect,
implements = homelib.assert.implements;
implements = require('implementjs').implements;

describe('KnxIpDriver', function() {

Expand Down
63 changes: 0 additions & 63 deletions test/assertTest.js

This file was deleted.

0 comments on commit e3d6f7c

Please sign in to comment.