Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: add feature flagging for logic tst #5460

Merged
merged 1 commit into from
May 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions tests/logictest/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,15 @@ def config_from_env():

mysql_port = os.getenv("QUERY_MYSQL_HANDLER_PORT")
if mysql_port is not None:
mysql_config['port'] = mysql_port
mysql_config['port'] = int(mysql_port)

http_host = os.getenv("QUERY_HTTP_HANDLER_HOST")
if http_host is not None:
http_config["host"] = http_host

http_port = os.getenv("QUERY_HTTP_HANDLER_PORT")
if http_port is not None:
http_config['port'] = http_port
http_config['port'] = int(http_port)

mysql_database = os.getenv("MYSQL_DATABASE")
if mysql_database is not None:
Expand Down
21 changes: 13 additions & 8 deletions tests/logictest/main.py
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
import os

from mysql_runner import TestMySQL
from http_runner import TestHttp

from config import mysql_config, http_config

if __name__ == '__main__':
mySQL = TestMySQL("mysql")
mySQL.set_driver(mysql_config)
mySQL.set_label("mysql")
mySQL.run_sql_suite()
disable_mysql_test = os.getenv("DISABLE_MYSQL_LOGIC_TEST")
if disable_mysql_test is not None:
mySQL = TestMySQL("mysql")
mySQL.set_driver(mysql_config)
mySQL.set_label("mysql")
mySQL.run_sql_suite()

http = TestHttp("http")
http.set_driver(http_config)
http.set_label("http")
http.run_sql_suite()
disable_http_test = os.getenv("DISABLE_HTTP_LOGIC_TEST")
if disable_http_test is not None:
http = TestHttp("http")
http.set_driver(http_config)
http.set_label("http")
http.run_sql_suite()