Skip to main content

rf-se-dtl-selectors-plugin

Build Status

DOM testing library inspired selectors for Robot Framework SeleniumLibrary.

Installation

To install this plugin from PyPI, run:

pip install rf-se-dtl-selectors-plugin

Usage

In order to use selector provided by this plugin, load SeleniumLibrary with TestingLibrarySelectorsPlugin in the plugin array:

*** Settings ***
Library         SeleniumLibrary    plugins=TestingLibrarySelectorsPlugin

*** Test cases ***
Click input element
    Click element  placeholder:Search

The plugin provides alttext, label, placeholder, testid, text, and title selectors. See acceptance_tests directory for usage examples. These locators are automatically registered when the plugin is initialized.

All attribute and text values are passed to normalize-space() XPath function before comparison with the given value.

In addition to the locator strategies, this plugin provides Get Xpath keyword to get the XPath expression for given locator. For example:

*** Settings ***
Library         SeleniumLibrary    plugins=TestingLibrarySelectorsPlugin

*** Test Cases ***
Find elements with xpath
    ${xpath}=  Get Xpath  placeholder:Search
    Click element  xpath:${xpath}

Testing

Check and automatically fix formatting with:

pycodestyle TestingLibrarySelectorsPlugin
autopep8 -aaar --in-place TestingLibrarySelectorsPlugin

Run static analysis with:

pylint -E --enable=invalid-name,unused-import,useless-object-inheritance TestingLibrarySelectorsPlugin

Run unit tests:

# Run unit tests
python3 -m unittest discover -s unit_tests/

# Run unit tests with coverage analysis
coverage run \
    --branch \
    --source TestingLibrarySelectorsPlugin/ \
    -m unittest discover -s unit_tests/
coverage report -m

Run acceptance tests in Docker container:

# Build image
docker build . -t atest

# Run acceptance tests
docker run --rm atest

# Run acceptance tests and get test output to ./out
docker run -v $(pwd)/out:/out --rm atest -d /out -L TRACE:INFO

Metadata

Release files for rf-se-dtl-selectors-plugin 0.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for rf-se-dtl-selectors-plugin 0.4.1
File Size Uploaded Provenance Actions
rf-se-dtl-selectors-plugin-0.4.1.tar.gz 4.5 kB Without provenance Details for rf-se-dtl-selectors-plugin-0.4.1.tar.gz

Release files / rf-se-dtl-selectors-plugin-0.4.1.tar.gz

Download URL rf-se-dtl-selectors-plugin-0.4.1.tar.gz
Size 4.5 kB
Tags Source
SHA-256 checksum
How to use checksums
7545d9229c1ee3d250a900b3528618e731bd5b2f864b0079b04c9be7080c4562
BLAKE2b-256 checksum
How to use checksums
d04da1a18f3c83875461d3ad919027a0c486cdb9ebbfada50f32d0a73d4e9094
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.53.0 CPython/3.7.1

Security for rf-se-dtl-selectors-plugin 0.4.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page