[pgAdmin4][Patch]: Feature #4202 Implement new framework to test Reverse Engineering SQL

From: Akshay Joshi <akshay(dot)joshi(at)enterprisedb(dot)com>
To: pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>
Subject: [pgAdmin4][Patch]: Feature #4202 Implement new framework to test Reverse Engineering SQL
Date: 2019-06-13 11:52:11
Message-ID: CANxoLDe_FGeAnGy9Vo22VBKRfd8-=yb4AbZcE4AbyR-tUnYgBg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Hi Hackers

I have implemented the new test framework to test the Reverse Engineering
SQL. I have integrated it as a part of API/Regression test suite. It will
work when we run all the test cases or module wise test case.

*How it works*: Attached patch contains the generic framework to read all
the JSON files from the *tests->version based (example 9.6_plus, 10_plus or
default) folder. *Run all the test scenarios present in the JSON file in
sequential order.

Format of the JSON file is mentioned in
"<path_of_source>web/pgadmin/browser/server_groups/servers/databases/casts/tests/default/test.json"

For expected SQL we will have following two options:

- Provide the expected sql in scenario itself as parameter *"expected_sql"
: "<SQL>"*.
- Create a output file with any name in the same directory where the
JSON file resides and specify the parameter "*expected_sql_file": "<name
of the file>"*

Attached patch contains both the above mentioned examples.

Please review it.

--
*Thanks & Regards*
*Akshay Joshi*

*Sr. Software Architect*
*EnterpriseDB Software India Private Limited*
*Mobile: +91 976-788-8246*

Attachment Content-Type Size
Test_Re_SQL.patch application/octet-stream 15.2 KB

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Akshay Joshi 2019-06-13 12:34:53 pgAdmin 4 commit: Fix syntax error for Default value of column. It is a
Previous Message Aditya Toshniwal 2019-06-13 06:22:53 [pgAdmin][RM4357] Connection restoration issue after restart and refresh pgadmin page