test_t1_59_ManageDistrictsSchoolsAndCourses.py 文件源码

python
阅读 17 收藏 0 点赞 0 评论 0

项目:test-automation 作者: openstax 项目源码 文件源码
def test_admin_set_the_course_scholastic_year_100135(self):
        """Set the course scholastic year.

        Steps:

        Expected Result:
        """
        self.ps.test_updates['name'] = 't1.59.021' \
            + inspect.currentframe().f_code.co_name[4:]
        self.ps.test_updates['tags'] = ['t1', 't1.59', 't1.59.021', '100135']
        self.ps.test_updates['passed'] = False

        # Test steps and verification assertions
        self.admin.wait.until(
            expect.visibility_of_element_located(
                (By.PARTIAL_LINK_TEXT, 'Course Organization')
            )
        ).click()
        self.admin.wait.until(
            expect.visibility_of_element_located(
                (By.PARTIAL_LINK_TEXT, 'Courses')
            )
        ).click()

        # Create the course
        self.admin.find(By.XPATH, "//a[text()='Add Course']").click()
        self.admin.find(
            By.ID, "course_year"
        ).send_keys((Keys.DELETE * 4) + str(datetime.date.today().year))

        self.ps.test_updates['passed'] = True

    # Case C100136 - 022 - Admin | Set the number of sections
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号