Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bO2cz-00052N-Ta for pgadmin-hackers@arkaria.postgresql.org; Fri, 15 Jul 2016 12:54:02 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bO2cz-0006gh-BI for pgadmin-hackers@arkaria.postgresql.org; Fri, 15 Jul 2016 12:54:01 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bO2cy-0006gW-IL for pgadmin-hackers@postgresql.org; Fri, 15 Jul 2016 12:54:00 +0000 Received: from mail-it0-x22f.google.com ([2607:f8b0:4001:c0b::22f]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1bO2cv-0007JC-AJ for pgadmin-hackers@postgresql.org; Fri, 15 Jul 2016 12:53:59 +0000 Received: by mail-it0-x22f.google.com with SMTP id f6so7843512ith.0 for ; Fri, 15 Jul 2016 05:53:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=enterprisedb-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=k6O4YAlzx5RWGOa4W4GW4D2EFgy07bBs4ig5kaYm3lA=; b=UCL68RPOAfWVjSnE1RAh5XqGmdJ9HvniEy2qZPvLWT3cnD5f8CTv33GCpwprkMKtTy Wd9yUxf30Dzn5SXKIwAxG95lBAcByDGSXQ6iNBQxSueke6kKxzOV4wniHDU+v6mPkWId +fxtBL5OuT/8zrbyzinNiePpm3JS75+VqUUltIpUEraTTnetGPciOU31wopQllwth+49 iuIYo0tiSlLCooljs/zc9uxONGZfbVnXjcoxXn+0rBHLWPJ11edx31z6xCtDXn6qiOYQ kRO8ySzJJcL9nEOgcpAcNcumKG8+grnKMXLuZjDLki6Uhl6Gm/JfbEyQPqbDJ4u3kD4U iWIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=k6O4YAlzx5RWGOa4W4GW4D2EFgy07bBs4ig5kaYm3lA=; b=Ejr7imLRDxlIJWAZ9Nd3gF2OXcNRcB6p4kGz2Jz5yIwtJZKGsEyMMOKhw7Ag2G8XAa DVloRW0XbbTmSI0b9OyfYXhOpag0MO78g+MugRnBBTcnCxxC8hso0pu4HYvkNEdE4IuA 2HNBv6d1IJvetw7CgQKFMrg/HeR9i71j3GVukYBWyRPDgrP4KlBxH9CYQzJ6Q4+OLpUP CXKAvoVHHSPZMm0kY3gKnoqf7DdEaGBv2HiVuXILKeMfrKTdDSZq24AZErSVRn5HwPwt Ejf4ssd8Vp5aj2CjWAmu2foYlbgSpqyoIpWb5mKv0hyWMdVAtTBw9leRhMCmLbgJf3Hg IQRQ== X-Gm-Message-State: ALyK8tKiqiMEwOh9jCvWPh0peqTbDXr9ljpSxKXUc6IIKCPe3rDnkndmSwtYVlOAASEyNyjT2EQ6vACRWoQanptrDDhRwMWmBnmKZbHzRU/AFQUgXCt4I6oBYcOhAu+zqTrjP10iTLDPd5HEWmgwEy0UYAKSIRlBnGFVaRNIbl2riIUPrynZ2HQ2YAc8M0A9iGx2XyjOxQ== X-Received: by 10.36.53.211 with SMTP id k202mr21098135ita.59.1468587235876; Fri, 15 Jul 2016 05:53:55 -0700 (PDT) Received: from mail-io0-f172.google.com (mail-io0-f172.google.com. [209.85.223.172]) by smtp.gmail.com with ESMTPSA id f9sm3306364ioi.2.2016.07.15.05.53.55 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 15 Jul 2016 05:53:55 -0700 (PDT) Received: by mail-io0-f172.google.com with SMTP id m101so103055271ioi.2 for ; Fri, 15 Jul 2016 05:53:55 -0700 (PDT) X-Received: by 10.107.201.138 with SMTP id z132mr20825785iof.156.1468587234755; Fri, 15 Jul 2016 05:53:54 -0700 (PDT) MIME-Version: 1.0 Received: by 10.64.208.97 with HTTP; Fri, 15 Jul 2016 05:53:53 -0700 (PDT) In-Reply-To: References: From: Dave Page Date: Fri, 15 Jul 2016 13:53:53 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: pgAdmin IV : Unittest modular patch To: Navnath Gadakh Cc: pgadmin-hackers , Kanchan Mohitey Content-Type: multipart/alternative; boundary=94eb2c0b86ec7311a80537ac1ca3 X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgadmin-hackers Precedence: bulk Sender: pgadmin-hackers-owner@postgresql.org --94eb2c0b86ec7311a80537ac1ca3 Content-Type: text/plain; charset=UTF-8 Hi On Mon, Jul 11, 2016 at 2:16 PM, Navnath Gadakh < navnath.gadakh@enterprisedb.com> wrote: > Hi Dave, > PFA updated patch for modular API test cases. > > On Mon, Jul 11, 2016 at 5:11 PM, Dave Page > wrote: > >> >> >> On Fri, Jul 8, 2016 at 2:30 PM, Navnath Gadakh < >> navnath.gadakh@enterprisedb.com> wrote: >> >>> >>> Hi Dave, >>> >>> PFA patch for modular API test cases. >>> >>> Kindly, review the same and let me know for any modification. >>> >> >> Please re-create the patch so that it doesn't revert various changes made >> to config.py etc. over the last couple of weeks. >> > > config.py file was not updated at my end, I have updated it in the > current patch. I have also added code related to advance test data > configuration which was created by Priyanka (Seprated the test data > configuration files). > > >> What is the patch for? Is it fixing issues in Priyanka's last patch, or >> something else? >> This patch is for - >> 1. Now we can run testsuite node/module wise(like for browser only, for >> databases only) OR for all nodes/modules >> 2. I have modified the existing functionality for testsuite and all test >> case classes (Made all test cases independently runnable, removed >> the priority logic). >> > > For more details please refer the file 'regression/README'. > When running all tests, I get: ... ... ' (HEAD, OPTIONS, GET) -> redirects.static>, ' (HEAD, OPTIONS, GET) -> backup.static>, ' (HEAD, POST, OPTIONS, GET) -> security.reset_password>, ' (HEAD, OPTIONS, GET) -> about.static>]) Traceback (most recent call last): File "regression/testsuite.py", line 151, in suite = get_suite(args, test_client) File "regression/testsuite.py", line 75, in get_suite TestsGeneratorRegistry.load_generators('pgadmin') File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/route.py", line 56, in load_generators module = import_module(module_name) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/importlib/__init__.py", line 37, in import_module __import__(name) File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/server_groups/servers/databases/tests/test_db_add.py", line 14, in from regression import test_utils as utils File "/Users/dpage/git/pgadmin4/web/regression/test_utils.py", line 23, in def get_ids(url=config.APP_ROOT + '/regression/parent_id.pkl'): AttributeError: 'module' object has no attribute 'APP_ROOT' That's not overly surprising, as we don't have an APP_ROOT setting in the config (nor should we - it should be calculated dynamically). Please fix, and remember to test your patches against a clean copy of the git tree in the future! Thanks! -- Dave Page VP, Chief Architect, Tools & Installers EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company Blog: http://pgsnake.blogspot.com Twitter: @pgsnake --94eb2c0b86ec7311a80537ac1ca3 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi

On Mon, Jul 11, 2016 at 2:16 PM, Navnath Gadakh <= ;navna= th.gadakh@enterprisedb.com> wrote:
Hi Dave,
PFA updated patch for modular API test cases.

<= /blockquote>
=C2=A0 =C2=A0 For more details please re= fer the file 'regression/README'.

When running all tests, I get:

<= /div>
...
...
=C2= =A0<Rule '//static/<filename>' (HEAD, OPTIONS, GET) -> = redirects.static>,
=C2=A0<Rule '/= backup/<filename>' (HEAD, OPTIONS, GET) -> backup.static>,<= /div>
=C2=A0<Rule '/reset/<token>= 9; (HEAD, POST, OPTIONS, GET) -> security.reset_password>,
=C2=A0<Rule '/about/<filename>' (HEA= D, OPTIONS, GET) -> about.static>])
T= raceback (most recent call last):
=C2=A0 Fi= le "regression/testsuite.py", line 151, in <module>
=C2=A0 =C2=A0 suite =3D get_suite(args, test_clien= t)
=C2=A0 File "regression/testsuite.p= y", line 75, in get_suite
=C2=A0 =C2= =A0 TestsGeneratorRegistry.load_generators('pgadmin')
=C2=A0 File "/Users/dpage/git/pgadmin4/web/pgadmin/= utils/route.py", line 56, in load_generators
=C2=A0 =C2=A0 module =3D import_module(module_name)
=C2=A0 File "/System/Library/Frameworks/Python.framew= ork/Versions/2.7/lib/python2.7/importlib/__init__.py", line 37, in imp= ort_module
=C2=A0 =C2=A0 __import__(name)
=C2=A0 File "/Users/dpage/git/pgadmin4/= web/pgadmin/browser/server_groups/servers/databases/tests/test_db_add.py&qu= ot;, line 14, in <module>
=C2=A0 =C2= =A0 from regression import test_utils as utils
=C2=A0 File "/Users/dpage/git/pgadmin4/web/regression/test_utils.p= y", line 23, in <module>
=C2=A0 = =C2=A0 def get_ids(url=3Dconfig.APP_ROOT + '/regression/parent_id.pkl&#= 39;):
AttributeError: 'module' obje= ct has no attribute 'APP_ROOT'

That's not overly surprising, as= we don't have an APP_ROOT setting in the config (nor should we - it sh= ould be calculated dynamically). Please fix, and remember to test your patc= hes against a clean copy of the git tree in the future!

Thanks!

--
--94eb2c0b86ec7311a80537ac1ca3--