ol.Tile inherits from goog.events.EventTarget

This commit is contained in:
Éric Lemoine
2012-07-09 21:33:08 +02:00
parent f9cb029a74
commit e4ff1a7574
3 changed files with 15 additions and 15 deletions

View File

@@ -34,7 +34,7 @@ describe("ol.Tile", function() {
});
it("fires a load event", function() {
var spy = jasmine.createSpy();
tile.events_.register('load', spy);
goog.events.listen(tile, 'load', spy);
tile.handleImageLoad();
expect(spy).toHaveBeenCalled();
});
@@ -57,7 +57,7 @@ describe("ol.Tile", function() {
});
it("fires a load event", function() {
var spy = jasmine.createSpy();
tile.events_.register('error', spy);
goog.events.listen(tile, 'error', spy);
tile.handleImageError();
expect(spy).toHaveBeenCalled();
});