From 4e10d330ee92602a21f1ae90cf12abaa8936b564 Mon Sep 17 00:00:00 2001 From: Churikova Tetiana Date: Wed, 25 Apr 2018 11:25:24 +0300 Subject: [PATCH] test git config - att 1 --- test/end-to-end/pages/thirdparty/github.py | 2 + test/end-to-end/tests/test_contracts.py | 44 +++++++++++----------- 2 files changed, 24 insertions(+), 22 deletions(-) diff --git a/test/end-to-end/pages/thirdparty/github.py b/test/end-to-end/pages/thirdparty/github.py index 488abf2..0939f7d 100644 --- a/test/end-to-end/pages/thirdparty/github.py +++ b/test/end-to-end/pages/thirdparty/github.py @@ -304,6 +304,8 @@ class GithubPage(BasePageObject): # logging.info(repo.git.push(repo_url)) logging.info(repo.git.push('origin', 'master')) logging.info(repo.git.fetch('--all')) + repo.git.config('user.email', test_data.config['DEV']['gh_login']) + repo.git.config('user.name', test_data.config['DEV']['gh_username']) repo.git.checkout('-b', branch) file = open(os.path.join(self.local_repo_path, file_to_modify), 'w') file.write("Autotest change: %s \r \n" % test_data.date_time) diff --git a/test/end-to-end/tests/test_contracts.py b/test/end-to-end/tests/test_contracts.py index 61d6e2f..70cb9f3 100644 --- a/test/end-to-end/tests/test_contracts.py +++ b/test/end-to-end/tests/test_contracts.py @@ -8,31 +8,31 @@ from tests import test_data @pytest.mark.sanity class TestLogin(BaseTestCase): - def test_deploy_new_contract(self): - - # Waiting for deployed contract; test_data.issue created here - self.github_org.create_new_bounty() - self.github_org.get_deployed_contract() - - # Navigate and check top bounty in "Open bounties" - bounties_page = BountiesPage(self.driver_dev) - bounties_page.get_bounties_page() - titles = bounties_page.bounty_titles.find_elements() - assert titles[0].text == test_data.issue['title'] + # def test_deploy_new_contract(self): + # + # # Waiting for deployed contract; test_data.issue created here + # self.github_org.create_new_bounty() + # self.github_org.get_deployed_contract() + # + # # Navigate and check top bounty in "Open bounties" + # bounties_page = BountiesPage(self.driver_dev) + # bounties_page.get_bounties_page() + # titles = bounties_page.bounty_titles.find_elements() + # assert titles[0].text == test_data.issue['title'] def test_new_claim(self): self.github_dev.create_pr_git('test_branch_%s' % self.github_dev.time_now) - self.github_dev.open_pr_github('Fixes') - - # check new claim in "Open bounties" - bounties_page = BountiesPage(self.driver_dev) - bounties_page.get_bounties_page() - bounties_page.check_bounty_claims_amount(test_data.issue['title'], '1 open claim') - - # check new claim in "Activity" - activity_page = ActivityPage(self.driver_dev) - activity_page.get_activity_page() - activity_page.check_activity_is_presented('Submitted a claim for ', test_data.issue['title']) + # self.github_dev.open_pr_github('Fixes') + # + # # check new claim in "Open bounties" + # bounties_page = BountiesPage(self.driver_dev) + # bounties_page.get_bounties_page() + # bounties_page.check_bounty_claims_amount(test_data.issue['title'], '1 open claim') + # + # # check new claim in "Activity" + # activity_page = ActivityPage(self.driver_dev) + # activity_page.get_activity_page() + # activity_page.check_activity_is_presented('Submitted a claim for ', test_data.issue['title'])