*** Settings ***
Library SeleniumLibrary
*** Variables ***
${URL} https://example.com
*** Test Cases ***
首页访问测试
Open Browser ${URL} Chrome
Title Should Be Example Domain
✅ 报告与日志
自动生成详细的 HTML 报告 和 日志文件,直观展示测试结果与错误原因。
3. 适用场景
场景
工具/库
Web 自动化测试
SeleniumLibrary
API 接口测试
RequestsLibrary
移动端测试
AppiumLibrary
数据库验证
DatabaseLibrary
文件/系统操作
BuiltIn / OperatingSystem 库
4. 安装与快速开始
步骤 1:安装 Robot Framework
pip install robotframework
步骤 2:安装所需库(以 Selenium 为例)
pip install robotframework-seleniumlibrary
步骤 3:编写第一个测试用例(login_test.robot)
*** Settings ***
Library SeleniumLibrary
*** Test Cases ***
验证百度首页标题
Open Browser https://www.baidu.com Chrome
Title Should Be 百度一下,你就知道
Close Browser
根据矩阵乘法规则,编程计算矩阵的乘积。函数fix_prod_ele()是基本方法编写,函数fix_prod_opt()是优化方法编写。
程序代码
#define N 3
#define M 4
typedef int fix_matrix1[N][M];
typedef int fix_matrix2[M][N];
int fix_prod_ele(f…
系统梳理提升 Mac Finder 体验的实用设置与技巧,助你用更高效的方式管理文件。文末引出进阶选择 Path Finder。 阅读原文请转到:https://jimmysong.io/blog/customize-finder-for-efficiency/ 作为一个用 Mac 多年的用户,我始终觉得 Finder 虽…