跳转到主要内容

使用Python简化为Robot Framework创建大型测试库的工具。

项目描述

使用Python简化为Robot Framework创建大型测试库的工具。

代码稳定,版本1.0已被SeleniumLibrary使用。更好的文档和打包工作仍在进行中。

示例

"""Main library."""

from robotlibcore import HybridCore

from mystuff import Library1, Library2


class MyLibrary(HybridCore):
    """General library documentation."""

    def __init__(self):
        libraries = [Library1(), Library2()]
        HybridCore.__init__(self, libraries)
"""Library components."""

from robotlibcore import keyword


class Library1(object):

    @keyword
    def example(self):
        """Keyword documentation."""
        pass

    @keyword
    def another_example(self, arg1, arg2='default'):
        pass

    def not_keyword(self):
        pass


class Library2(object):

    @keyword('Custom name')
    def this_name_is_not_used(self):
        pass

    @keyword(tags=['tag', 'another'])
    def tags(self):
        pass

项目详情


下载文件

下载适合您平台的文件。如果您不确定要选择哪个,请了解有关安装包的更多信息。

源代码发行版

robotlibcore-temp-1.0.2.tar.gz (4.3 kB 查看哈希值)

上传时间: 来源

支持