Exemple #1
0
    def test_qtfyzf(self):
        """其他费用支付"""
        driver = self.driver
        driver.get(self.base_url)

        #longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_qtfyzf()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/otherFeeSearchPre.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search()']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_zfdw(), "支付单位")
        homepage.get_page_title()
        print("***测试通过***")
Exemple #2
0
    def test_ygtxl(self):
        """会计报表管理档案"""
        driver = self.driver
        driver.get(self.base_url)

        longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_kjad()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/fiReportfromAttSearch.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search()']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_ny(), "年月")
        homepage.get_page_title()
        print("***测试通过***")
Exemple #3
0
    def test5_edbb(self):
        """额度报表"""
        driver = self.driver
        driver.get(self.base_url)

        #longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_ysgl()

        homepage.sleep(0.4)

        homepage.click_edbb()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/finBudgetAccountingReportUnitSearchPreAction.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search()']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_nd(), "年度")

        homepage.get_page_title()

        print("***测试通过***")

        # 关闭窗口

        homepage.back_frame()

        driver.find_element_by_xpath("/html/body/div/div[2]/ul/i").click()
Exemple #4
0
	def test_hscsh(self):
		"""核算初始化"""
		driver = self.driver
		driver.get(self.base_url)

		#longin.login(self)

		# 初始化业务合同查询主页对象
		homepage = HomePage(self.driver)

		homepage.click_oa()

		homepage.sleep(0.5)
        
		homepage.click_cwgl()

		homepage.click_hscsh()


		homepage.switch_frame(driver.find_element_by_xpath("//iframe[@src='http://ehr.eascs.com/finBudgetManageByAccount.action?isReturn=NO']"))

		homepage.switch_frame("leftFrame")


		#driver.find_element_by_xpath("//*[@onclick='Search()']").click()
		#driver.refresh()

		homepage.get_windows_img()  # 调用基类截图方法


		#展开菜单
		driver.find_element_by_xpath("//tr[@id='datagrid-row-r2-2-42603']/td[2]/div/span").click()

		# 断言
		homepage.get_page_title()
		print("***测试通过***")

		#self.driver.quit()
		# 关闭窗口 

		homepage.back_frame()
		
		driver.find_element_by_xpath("/html/body/div/div[2]/ul/i").click()
Exemple #5
0
    def test_cxdjsp(self):
        """撤销单据审批"""
        driver = self.driver
        driver.get(self.base_url)

        #longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_cxdjsp()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/fiBillCancelSearchPre.action']"
            ))

        driver.find_element_by_xpath("//*[@onclick='btnSearch()']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_cxdjlx(), "撤消单据类型")
        homepage.get_page_title()
        print("***测试通过***")

        #self.driver.quit()
        #
        # 关闭窗口

        homepage.back_frame()

        driver.find_element_by_xpath("/html/body/div/div[2]/ul/i").click()
Exemple #6
0
    def test_NCfjzsq(self):
        """NC反记账申请"""
        driver = self.driver
        driver.get(self.base_url)

        longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_fjzsq()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/ncsettlementSearchPre.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search()']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_ztbm(), "单据状态")
        homepage.get_page_title()
        print("***测试通过***")

        #self.driver.quit()
        # 关闭窗口

        homepage.back_frame()

        driver.find_element_by_xpath("/html/body/div/div[2]/ul/i").click()
Exemple #7
0
    def test3_edgl(self):
        """额度管理"""
        driver = self.driver
        driver.get(self.base_url)

        #longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_ysgl()

        homepage.sleep(0.4)

        homepage.click_edgl()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/finBudgetAccountApplySearchPreAction.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search()']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_edlx(), "额度类型")

        homepage.get_page_title()

        print("***测试通过***")
Exemple #8
0
    def test4_edblsq(self):
        """额度比例申请"""
        driver = self.driver
        driver.get(self.base_url)

        #longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_ysgl()

        homepage.sleep(0.4)

        homepage.click_edblsq()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/finAccountingRatioSearchPre.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search();']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_billcode(), "单据编号")

        homepage.get_page_title()

        print("***测试通过***")
Exemple #9
0
    def test_fybx(self):
        """费用报销"""
        driver = self.driver
        driver.get(self.base_url)

        #longin.login(self)

        # 初始化对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_fybx()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/expenseClaimSearchPre.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search()']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_djbh(), "单据编号")
        homepage.get_page_title()
        print("***测试通过***")

        # 关闭窗口

        homepage.back_frame()

        driver.find_element_by_xpath("/html/body/div/div[2]/ul/i").click()
Exemple #10
0
	def test_xnjydwgl(self):
		"""虚拟经营单位管理"""
		driver = self.driver
		driver.get(self.base_url)

		#longin.login(self)

		# 初始化业务合同查询主页对象
		homepage = HomePage(self.driver)

		homepage.click_oa()

		homepage.sleep(0.5)
        
		homepage.click_cwgl()

		homepage.click_xnjydwgl()


		homepage.switch_frame(driver.find_element_by_xpath("//iframe[@src='http://oa2.eascs.com/eaoa/unitsFiSearchAction.do']"))


		driver.find_element_by_xpath("//*[@onclick='Search();']").click()
		#driver.refresh()

		homepage.get_windows_img()  # 调用基类截图方法

		# 断言

		self.assertEqual(homepage.get_gsbm(),"公司编码")
		homepage.get_page_title()
		print("***测试通过***")

		#self.driver.quit()
		# 关闭窗口 

		homepage.back_frame()
		
		driver.find_element_by_xpath("/html/body/div/div[2]/ul/i").click()
Exemple #11
0
    def test_ysycsq(self):
        """应收异常申请"""
        driver = self.driver
        driver.get(self.base_url)

        #longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_ysycsq()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/fiarexceptionSearchPre.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search();']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_jskh(), "结算客户")
        homepage.get_page_title()
        print("***测试通过***")

        #self.driver.quit()
        homepage.back_frame()

        driver.find_element_by_xpath("/html/body/div/div[2]/ul/i").click()
Exemple #12
0
    def test2_yjlc(self):
        """押金流程"""
        driver = self.driver
        driver.get(self.base_url)

        #longin.login(self)

        # 初始化业务合同查询主页对象
        homepage = HomePage(self.driver)

        homepage.click_oa()

        homepage.sleep(0.5)

        homepage.click_cwgl()

        homepage.click_yjxm()

        homepage.sleep(0.5)

        homepage.click_yjlc()

        homepage.switch_frame(
            driver.find_element_by_xpath(
                "//iframe[@src='http://oa2.eascs.com/eaoa/fiDepositLineSearchPre.do']"
            ))

        driver.find_element_by_xpath("//*[@onclick='Search()']").click()
        #driver.refresh()

        homepage.get_windows_img()  # 调用基类截图方法

        # 断言

        self.assertEqual(homepage.get_bz(), "币种")
        homepage.get_page_title()
        print("***测试通过***")