Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 401167d

Browse files
committed
tests(jqLite): add basic tests for the bind/unbind aliases
1 parent fa74b0b commit 401167d

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

test/jqLiteSpec.js

+15
Original file line numberDiff line numberDiff line change
@@ -2323,4 +2323,19 @@ describe('jqLite', function() {
23232323
expect(onLoadCallback).toHaveBeenCalledOnce();
23242324
});
23252325
});
2326+
2327+
2328+
describe('bind/unbind', function() {
2329+
if (!_jqLiteMode) return;
2330+
2331+
it('should alias bind() to on()', function() {
2332+
var element = jqLite(a);
2333+
expect(element.bind).toBe(element.on);
2334+
});
2335+
2336+
it('should alias unbind() to off()', function() {
2337+
var element = jqLite(a);
2338+
expect(element.unbind).toBe(element.off);
2339+
});
2340+
});
23262341
});

0 commit comments

Comments
 (0)