fixup tests
This commit is contained in:
parent
69939ec2a3
commit
20bbbbad0c
3 changed files with 10 additions and 10 deletions
|
@ -33,7 +33,7 @@ def test_map_load_with_owner(anonymap, live_server, owner_session):
|
||||||
expect(save).to_be_visible()
|
expect(save).to_be_visible()
|
||||||
add_marker = owner_session.get_by_title("Draw a marker")
|
add_marker = owner_session.get_by_title("Draw a marker")
|
||||||
expect(add_marker).to_be_visible()
|
expect(add_marker).to_be_visible()
|
||||||
edit_settings = owner_session.get_by_title("Edit map settings")
|
edit_settings = owner_session.get_by_title("Edit map properties")
|
||||||
expect(edit_settings).to_be_visible()
|
expect(edit_settings).to_be_visible()
|
||||||
edit_permissions = owner_session.get_by_title("Update permissions and editors")
|
edit_permissions = owner_session.get_by_title("Update permissions and editors")
|
||||||
expect(edit_permissions).to_be_visible()
|
expect(edit_permissions).to_be_visible()
|
||||||
|
@ -64,7 +64,7 @@ def test_map_load_with_anonymous_but_editable_layer(
|
||||||
expect(save).to_be_visible()
|
expect(save).to_be_visible()
|
||||||
add_marker = page.get_by_title("Draw a marker")
|
add_marker = page.get_by_title("Draw a marker")
|
||||||
expect(add_marker).to_be_visible()
|
expect(add_marker).to_be_visible()
|
||||||
edit_settings = page.get_by_title("Edit map settings")
|
edit_settings = page.get_by_title("Edit map properties")
|
||||||
expect(edit_settings).to_be_hidden()
|
expect(edit_settings).to_be_hidden()
|
||||||
edit_permissions = page.get_by_title("Update permissions and editors")
|
edit_permissions = page.get_by_title("Update permissions and editors")
|
||||||
expect(edit_permissions).to_be_hidden()
|
expect(edit_permissions).to_be_hidden()
|
||||||
|
|
|
@ -40,7 +40,7 @@ def test_map_update_with_owner(map, live_server, login):
|
||||||
expect(save).to_be_visible()
|
expect(save).to_be_visible()
|
||||||
add_marker = page.get_by_title("Draw a marker")
|
add_marker = page.get_by_title("Draw a marker")
|
||||||
expect(add_marker).to_be_visible()
|
expect(add_marker).to_be_visible()
|
||||||
edit_settings = page.get_by_title("Edit map settings")
|
edit_settings = page.get_by_title("Edit map properties")
|
||||||
expect(edit_settings).to_be_visible()
|
expect(edit_settings).to_be_visible()
|
||||||
edit_permissions = page.get_by_title("Update permissions and editors")
|
edit_permissions = page.get_by_title("Update permissions and editors")
|
||||||
expect(edit_permissions).to_be_visible()
|
expect(edit_permissions).to_be_visible()
|
||||||
|
@ -67,7 +67,7 @@ def test_map_update_with_anonymous_but_editable_datalayer(
|
||||||
enable.click()
|
enable.click()
|
||||||
add_marker = page.get_by_title("Draw a marker")
|
add_marker = page.get_by_title("Draw a marker")
|
||||||
expect(add_marker).to_be_visible()
|
expect(add_marker).to_be_visible()
|
||||||
edit_settings = page.get_by_title("Edit map settings")
|
edit_settings = page.get_by_title("Edit map properties")
|
||||||
expect(edit_settings).to_be_hidden()
|
expect(edit_settings).to_be_hidden()
|
||||||
edit_permissions = page.get_by_title("Update permissions and editors")
|
edit_permissions = page.get_by_title("Update permissions and editors")
|
||||||
expect(edit_permissions).to_be_hidden()
|
expect(edit_permissions).to_be_hidden()
|
||||||
|
@ -115,7 +115,7 @@ def test_map_update_with_editor(map, live_server, login, user):
|
||||||
expect(save).to_be_visible()
|
expect(save).to_be_visible()
|
||||||
add_marker = page.get_by_title("Draw a marker")
|
add_marker = page.get_by_title("Draw a marker")
|
||||||
expect(add_marker).to_be_visible()
|
expect(add_marker).to_be_visible()
|
||||||
edit_settings = page.get_by_title("Edit map settings")
|
edit_settings = page.get_by_title("Edit map properties")
|
||||||
expect(edit_settings).to_be_visible()
|
expect(edit_settings).to_be_visible()
|
||||||
edit_permissions = page.get_by_title("Update permissions and editors")
|
edit_permissions = page.get_by_title("Update permissions and editors")
|
||||||
expect(edit_permissions).to_be_visible()
|
expect(edit_permissions).to_be_visible()
|
||||||
|
@ -144,7 +144,7 @@ def test_permissions_form_with_editor(map, datalayer, live_server, login, user):
|
||||||
def test_owner_has_delete_map_button(map, live_server, login):
|
def test_owner_has_delete_map_button(map, live_server, login):
|
||||||
page = login(map.owner)
|
page = login(map.owner)
|
||||||
page.goto(f"{live_server.url}{map.get_absolute_url()}?edit")
|
page.goto(f"{live_server.url}{map.get_absolute_url()}?edit")
|
||||||
settings = page.get_by_title("Edit map settings")
|
settings = page.get_by_title("Edit map properties")
|
||||||
expect(settings).to_be_visible()
|
expect(settings).to_be_visible()
|
||||||
settings.click()
|
settings.click()
|
||||||
advanced = page.get_by_text("Advanced actions")
|
advanced = page.get_by_text("Advanced actions")
|
||||||
|
@ -160,7 +160,7 @@ def test_editor_do_not_have_delete_map_button(map, live_server, login, user):
|
||||||
map.save()
|
map.save()
|
||||||
page = login(user)
|
page = login(user)
|
||||||
page.goto(f"{live_server.url}{map.get_absolute_url()}?edit")
|
page.goto(f"{live_server.url}{map.get_absolute_url()}?edit")
|
||||||
settings = page.get_by_title("Edit map settings")
|
settings = page.get_by_title("Edit map properties")
|
||||||
expect(settings).to_be_visible()
|
expect(settings).to_be_visible()
|
||||||
settings.click()
|
settings.click()
|
||||||
advanced = page.get_by_text("Advanced actions")
|
advanced = page.get_by_text("Advanced actions")
|
||||||
|
|
|
@ -46,7 +46,7 @@ def test_can_change_picto_at_map_level(map, live_server, page, pictos):
|
||||||
expect(marker).to_have_count(1)
|
expect(marker).to_have_count(1)
|
||||||
# Should have default img
|
# Should have default img
|
||||||
expect(marker).to_have_attribute("src", "/static/umap/img/marker.png")
|
expect(marker).to_have_attribute("src", "/static/umap/img/marker.png")
|
||||||
edit_settings = page.get_by_title("Edit map settings")
|
edit_settings = page.get_by_title("Edit map properties")
|
||||||
expect(edit_settings).to_be_visible()
|
expect(edit_settings).to_be_visible()
|
||||||
edit_settings.click()
|
edit_settings.click()
|
||||||
shape_settings = page.get_by_text("Default shape properties")
|
shape_settings = page.get_by_text("Default shape properties")
|
||||||
|
@ -146,7 +146,7 @@ def test_can_use_remote_url_as_picto(map, live_server, page, pictos):
|
||||||
expect(marker).to_have_count(1)
|
expect(marker).to_have_count(1)
|
||||||
# Should have default img
|
# Should have default img
|
||||||
expect(marker).to_have_attribute("src", "/static/umap/img/marker.png")
|
expect(marker).to_have_attribute("src", "/static/umap/img/marker.png")
|
||||||
edit_settings = page.get_by_title("Edit map settings")
|
edit_settings = page.get_by_title("Edit map properties")
|
||||||
expect(edit_settings).to_be_visible()
|
expect(edit_settings).to_be_visible()
|
||||||
edit_settings.click()
|
edit_settings.click()
|
||||||
shape_settings = page.get_by_text("Default shape properties")
|
shape_settings = page.get_by_text("Default shape properties")
|
||||||
|
@ -186,7 +186,7 @@ def test_can_use_char_as_picto(map, live_server, page, pictos):
|
||||||
marker = page.locator(".umap-div-icon span")
|
marker = page.locator(".umap-div-icon span")
|
||||||
# Should have default img, so not a span
|
# Should have default img, so not a span
|
||||||
expect(marker).to_have_count(0)
|
expect(marker).to_have_count(0)
|
||||||
edit_settings = page.get_by_title("Edit map settings")
|
edit_settings = page.get_by_title("Edit map properties")
|
||||||
expect(edit_settings).to_be_visible()
|
expect(edit_settings).to_be_visible()
|
||||||
edit_settings.click()
|
edit_settings.click()
|
||||||
shape_settings = page.get_by_text("Default shape properties")
|
shape_settings = page.get_by_text("Default shape properties")
|
||||||
|
|
Loading…
Reference in a new issue