Skip to main content

Call RobotFramework keywords from Python

Project description

robotframework-libraryproxy

Simple library for calling RobotFramework keywords from Python, with the possibility to log them in the output.

Example Python library:

from Browser import Browser
from robotlibraryproxy import library_proxy

def do_something_in_browser(self):
    with library_proxy(Browser) as browser:
        browser.new_browser(headless=False)
        browser.new_page("https://example.com")
        browser.click("text=More Information...")

or another way as python descriptor:

from Browser import Browser
from robotlibraryproxy import library_proxy


class Dummy:

    browser: Browser = library_proxy()

    def do_something_in_browser(self):
        self.browser.new_browser(headless=False)
        self.browser.new_page("https://example.com")
        self.browser.click("text=More Information...")

Example Test case that uses this library:

*** Settings ***

Library    Dummy.py

# Library    Browser

*** Test Cases ***

a simple test
    Do Something In Browser

An excerpt from the Robot log:

Example from robot log

more comming soon...

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

robotframework_libraryproxy-0.3.0.tar.gz (8.8 kB view details)

Uploaded Source

Built Distribution

File details

Details for the file robotframework_libraryproxy-0.3.0.tar.gz.

File metadata

File hashes

Hashes for robotframework_libraryproxy-0.3.0.tar.gz
Algorithm Hash digest
SHA256 99f6136abdfd124d0af625f722a06fbe29c1eda0444c97ccf729b83e0aae46be
MD5 a9b0858298f9734d6ca6aa264a20d9ea
BLAKE2b-256 b0142402dbc54270a31240250af656ede719e89dfed729b2e40efd5d675b381f

See more details on using hashes here.

File details

Details for the file robotframework_libraryproxy-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for robotframework_libraryproxy-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6ec49118f1587248cf2ac0c05ac95353f5cdba9837a240e4be5e56017fb7ab5d
MD5 03c56549c080c66172ab4e31c8aa95d2
BLAKE2b-256 00e9ffde293b79d1fb9099f5370dd9e6c3545bc9f18aeacbb5b259d458b870cc

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page