mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
1) Splits the SQL query used to retrieve the Dependents, Dependencies, and Roles SQL file into multiple versioned files.
2) Add Unit Tests for each file. 3) Add ORDER BY into Copy Selection Feature test to ensure the results are retrieved always in the same order 4) Renamed the Scenario of the xss_checks_pgadmin_debugger_test and skip it for versions less than 9.1 5) Deleted unused __init__.py files.
This commit is contained in:
committed by
Akshay Joshi
parent
0e7efc0cf8
commit
3bf17d9df4
@@ -1,3 +1,12 @@
|
||||
##########################################################################
|
||||
#
|
||||
# pgAdmin 4 - PostgreSQL Tools
|
||||
#
|
||||
# Copyright (C) 2013 - 2017, The pgAdmin Development Team
|
||||
# This software is released under the PostgreSQL Licence
|
||||
#
|
||||
##########################################################################
|
||||
|
||||
import pyperclip
|
||||
import time
|
||||
|
||||
@@ -37,7 +46,7 @@ class CopySelectedQueryResultsFeatureTest(BaseFeatureTest):
|
||||
self.page.find_by_partial_link_text("Query Tool").click()
|
||||
self.page.click_tab('Query-1')
|
||||
time.sleep(5)
|
||||
ActionChains(self.page.driver).send_keys("SELECT * FROM test_table").perform()
|
||||
ActionChains(self.page.driver).send_keys("SELECT * FROM test_table ORDER BY some_column").perform()
|
||||
self.page.driver.switch_to_frame(self.page.driver.find_element_by_tag_name("iframe"))
|
||||
self.page.find_by_id("btn-flash").click()
|
||||
|
||||
|
||||
@@ -16,10 +16,14 @@ class CheckDebuggerForXssFeatureTest(BaseFeatureTest):
|
||||
"""Tests to check if Debugger is vulnerable to XSS."""
|
||||
|
||||
scenarios = [
|
||||
("Test table DDL generation", dict())
|
||||
("Tests to check if Debugger is vulnerable to XSS", dict())
|
||||
]
|
||||
|
||||
def before(self):
|
||||
with test_utils.Database(self.server) as (connection, _):
|
||||
if connection.server_version < 90100:
|
||||
self.skipTest("Functions tree node is not present in pgAdmin below PG v9.1")
|
||||
|
||||
# Some test function is needed for debugger
|
||||
test_utils.create_debug_function(self.server, "postgres",
|
||||
"test_function")
|
||||
|
||||
Reference in New Issue
Block a user