Robot Framework Testing
БесплатноБез исполняемых скриптовНе проверенExpert-level Robot Framework testing skill covering keyword-driven syntax, SeleniumLibrary, RequestsLibrary, custom Python keywords, data-driven testing…
от PramodDutta★ 253 звезды на GitHubОб этом скилле
Robot Framework Testing Skill
You are an expert QA automation engineer specializing in Robot Framework testing. When the user asks you to write, review, or debug Robot Framework tests, follow these detailed instructions.
Core Principles
- Keyword-driven design -- Robot Framework uses human-readable keywords. Write custom keywords that read like natural language:
Login As User,Verify Dashboard Is Displayed. - Separation of concerns -- Keep test cases, keywords, variables, and resource files separate. Test files should be high-level; keyword implementations go in resource files.
- Library ecosystem -- Use SeleniumLibrary for web UI, RequestsLibrary for APIs, DatabaseLibrary for DB, and custom Python libraries for domain logic.
- Data-driven testing -- Use
[Template]keyword with data tables or DataDriver library with CSV/Excel for bulk test data execution. - Readable reports -- Robot Framework generates
report.htmlandlog.htmlautomatically. Configure tags and documentation for clear test reporting.
Project Structure
Always organize Robot Framework projects with this structure:
tests/
web/
login.robot
dashboard.robot
checkout.robot
api/
users_api.robot
products_api.robot
smoke/
smoke_suite.robot
resources/
keywords/
common.robot
login_keywords.robot
api_keywords.robot
pages/
login_page.robot
dashboard_page.robot
locators/
login_locators.robot
dashboard_locators.robot
libraries/
CustomLibrary.py
DataHelper.py
data/
test_data.yaml
users.csv
config/
variables.robot
variables_ci.robot
results/
robot.yaml # pabot config
requirements.txt
Setup
Installation
pip install robotframework
pip install robotframework-seleniumlibrary
pip install robotframework-requests
pip install robotframework-databaselibrary
pip install robotframework-datadriver
pip install robotframework-pabot
pip install webdriver-manager
requirements.txt
robotframework>=7.0
robotframework-seleniumlibrary>=6.2
robotframework-requests>=0.9
robotframework-databaselibrary>=1.4
robotframework-datadriver>=1.8
robotframework-pabot>=2.18
webdriver-manager>=4.0
Basic Test Patterns
Web UI Test (tests/web/login.robot)
*** Settings ***
Library SeleniumLibrary
Resource ../../resources/keywords/login_keywords.robot
Resource ../../config/variables.robot
Suite Setup Open Browser ${BASE_URL} ${BROWSER}
Suite Teardown Close All Browsers
Test Setup Go To ${BASE_URL}/login
*** Test Cases ***
Login With Valid Credentials
[Documentation] Verify user can login with correct email and password
[Tags] smoke auth
Enter Email ${VALID_EMAIL}
Enter Password ${VALID_PASSWORD}
Click Login Button
Verify Dashboard Is Displayed
Page Should Contain Welcome
Login With Invalid Credentials Shows Error
[Documentation] Verify error message for wrong credentials
[Tags] regression auth
Enter Email [email protected]
Enter Password wrongpassword
Click Login Button
Wait Until Element Is Visible css:.error-message 5s
Element Should Contain css:.error-message Invalid credentials
Login Requires Email Field
[Documentation] Verify email validation on empty submit
[Tags] validation auth
Enter Password password123
Click Login Button
Page Should Contain Email is required
Variables File (config/variables.robot)
*** Variables ***
${BASE_URL} http://localhost:3000
${BROWSER} chrome
${IMPLICIT_WAIT} 10s
${VALID_EMAIL} [email protected]
${VALID_PASSWORD} password123
${ADMIN_EMAIL} [email protected]
${ADMIN_PASSWORD} admin123
${API_URL} http://localhost:3000/api
Custom Keywords
Login Keywords (resources/keywords/login_keywords.robot)
*** Settings ***
Library SeleniumLibrary
*** Keywords ***
Enter Email
[Arguments] ${email}
Wait Until Element Is Visible id:email 10s
Input Text id:email ${email}
Enter Password
[Arguments] ${password}
Input Text id:password ${password}
Click Login Button
Click Button css:button[type='submit']
Verify Dashboard Is Displayed
Wait Until Element Is Visible css:.dashboard 10s
Location Should Contain /dashboard
Login As User
[Arguments] ${email} ${password}
Go To ${BASE_URL}/login
Enter Email ${email}
Enter Password ${password}
Click Login Button
Verify Dashboard Is Displayed
Login As Admin
Login As User ${ADMIN_EMAIL} ${ADMIN_PASSWORD}
Logout
Click Element css:[data-testid='logout-btn']
Wait Until Element Is Visible css:.login-form 10s
Page Object Pattern
Login Page (resources/pages/login_page.robot)
*** Settings ***
Library SeleniumLibrary
*** Variables ***
$
Установить Robot Framework Testing в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл Robot Framework Testing?
Expert-level Robot Framework testing skill covering keyword-driven syntax, SeleniumLibrary, RequestsLibrary, custom Python keywords, data-driven testing, resource files, and parallel execution with Pabot.
Как установить скилл Robot Framework Testing?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл Robot Framework Testing запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic