From cca87dfa1df82be77462884a8fb726249b01bb2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nico=20H=C3=B6llerich?= Date: Sat, 27 Jun 2020 12:26:15 +0200 Subject: [PATCH] Revert "Add test for external tile loading." This reverts commit 076307ea5595c68b0b8e75a449d3d99c95f0d6e8. --- tests/run_tests.py | 11 ----------- tests/tests.html | 46 +--------------------------------------------- 2 files changed, 1 insertion(+), 56 deletions(-) diff --git a/tests/run_tests.py b/tests/run_tests.py index e22e9f0..87b6c68 100755 --- a/tests/run_tests.py +++ b/tests/run_tests.py @@ -183,17 +183,6 @@ class PannellumTester(object): assert self.browser.execute_script("var hs = viewer.getConfig().hotSpots[0]; return Math.abs(hs.yaw) < 0.001 && Math.abs(hs.pitch) < 0.001") print("PASS: hot spot dragging") - # Check multires with external tile loading - self.browser.execute_script("viewer.loadScene('multires-loader')") - time.sleep(5) - if create_ref: - self.take_screenshot("panorama", "tests/multires.png") - subprocess.call(["optipng", "-o7", "-strip", "all", "tests/multires.png"]) - else: - reference = Image.open("tests/multires.png") - comparator = self.take_screenshot("panorama") - self.equal_images(reference, comparator, "multires with external tile loading") - self.httpd.server_close() def get_browser(self, name=None): diff --git a/tests/tests.html b/tests/tests.html index 0125246..e9e8f5e 100644 --- a/tests/tests.html +++ b/tests/tests.html @@ -90,51 +90,7 @@ viewer = pannellum.viewer('panorama', { "dragHandlerFunc": console.log } ] - }, - - "multires-loader": { - "title": "multires title", - "type": "multires", - "hfov": 85, - "multiRes": { - "basePath": "../examples/multires", - "path": "/%l/%s%x%y", - "fallbackPath": "/fallback/%s", - "extension": "png", - "tileResolution": 256, - "maxLevel": 4, - "cubeResolution": 2048, - "loader": function(node){ - var resolver; - var rejector; - var promise = {}; - - promise.then = function(callback){ - resolver = callback; - return promise; - } - - promise.catch = function(callback){ - rejector = callback; - return promise; - } - - var img = document.createElement('img'); - img.onload = function () { - if(resolver) - resolver(img); - } - img.onerror = function(err) { - if(rejector) - rejector(err); - } - - img.src = node.uri; - - return promise; - } - } - } + } } });