mirror of
https://github.com/GNS3/gns3-server
synced 2024-11-12 19:38:57 +00:00
Fix tests on Windows
This commit is contained in:
parent
41026c74c1
commit
dd845eb096
@ -90,7 +90,7 @@ class IndexHandler:
|
||||
static = get_static_path(filename)
|
||||
|
||||
if not os.path.exists(static):
|
||||
static = get_static_path('web-ui/index.html')
|
||||
static = get_static_path(os.path.join('web-ui', 'index.html'))
|
||||
|
||||
yield from response.file(static)
|
||||
|
||||
|
@ -15,8 +15,11 @@
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import os
|
||||
|
||||
from gns3server.utils.static import get_static_path
|
||||
|
||||
|
||||
def test_get_static_path():
|
||||
assert get_static_path('test').endswith('gns3server/static/test')
|
||||
expected = os.path.join('gns3server', 'static', 'test')
|
||||
assert get_static_path('test').endswith(expected)
|
||||
|
Loading…
Reference in New Issue
Block a user