【RF库XML测试】Get Elements
Name:
Get Elements
Source:
XML <test library>
Arguments:
[ source | xpath ]
Returns a list of elements in the `source` matching the `xpath`.
The `source` can be a path to an XML file, a string containing XML, or an already parsed XML element. The `xpath` specifies which element to find. See the `introduction` for more details.
Elements matching the `xpath` are returned as a list. If no elements match, an empty list is returned. Use `Get Element` if you want to get exactly one match.
Starting test: Test Rf Api.Testxml.Get Elements
20170627 21:56:38.428 : INFO : ${children} = [<Element 'child' at 0x02FD9B18>, <Element 'child' at 0x02FD9B48>]
20170627 21:56:38.429 : INFO : Length is 2
20170627 21:56:38.430 : INFO : more text
20170627 21:56:38.431 : INFO : None
20170627 21:56:38.432 : INFO : ${children} = []
20170627 21:56:38.433 : INFO : Length is 0
20170627 21:56:38.434 : INFO : ${children} = [<Element 'child' at 0x02FD9CB0>, <Element 'child' at 0x02FD99B0>, <Element 'child' at 0x02FD9C80>]
20170627 21:56:38.435 : INFO : Length is 3
20170627 21:56:38.436 : INFO : ${elements} = [<Element 'second' at 0x02FD9BC0>, <Element 'second' at 0x02FD9DE8>]
20170627 21:56:38.438 : INFO : Length is 2
20170627 21:56:38.439 : INFO : {'id': '2'}
20170627 21:56:38.440 : INFO : {'id': 'child'}
20170627 21:56:38.441 : INFO : ${b} = <Element 'b' at 0x033E5020>
20170627 21:56:38.442 : INFO :
Argument types are:
<type 'str'>
<type 'unicode'>
20170627 21:56:38.443 : INFO : ${id} = <Element 'second' at 0x02FD9E60>
20170627 21:56:38.444 : INFO : Length is 1
20170627 21:56:38.446 : INFO : ${elem} = <Element 'second' at 0x02FD9D40>
20170627 21:56:38.446 : INFO :
Argument types are:
<type 'str'>
<type 'unicode'>
20170627 21:56:38.448 : INFO : ${elem} = <Element 'child' at 0x033E50F8>
20170627 21:56:38.449 : INFO :
Argument types are:
<type 'str'>
<type 'unicode'>
20170627 21:56:38.451 : INFO : ${elem} = <Element 'child' at 0x033E5068>
20170627 21:56:38.452 : INFO :
Argument types are:
<type 'NoneType'>
<type 'NoneType'>
Ending test: Test Rf Api.Testxml.Get Elements
【RF库XML测试】Get Elements的更多相关文章
- 【RF库XML测试】Get Element
Name:Get ElementSource:XML <test library>Arguments:[ source | xpath=. ]Returns an element in t ...
- 【RF库XML测试】Get Element Text
Name:Get Element TextSource:XML <test library>Arguments:[ source | xpath=. | normalize_whitesp ...
- 【RF库XML测试】Add Element
Name:Add ElementSource:XML <test library>Arguments:[ source | element | index=None | xpath=. ] ...
- 【RF库XML测试】通过xpath查找元素的说明
Tag names:当仅使用1个tag的时候,xpath匹配具有该标签名称的所有直接子元素. Paths:通过/符号连接tag名称,例如second/child将匹配父元素second下所有的chil ...
- 【RF库XML测试】Element Attribute Should Be
Name:Element Attribute Should BeSource:XML <test library>Arguments:[ source | name | expected ...
- 【RF库XML测试】parse xml
Name:Parse XmlSource:XML <test library>Arguments:[ source | keep_clark_notation=False ]Parses ...
- 【RF库XML测试】测试的XML文件说明
文件存放路径:C:\workspace\robotframework\test_rf_api\testdata\XML.xml 文件内容: <example> <first id=& ...
- 【RF库Collections测试】List Should Not Contain Duplicates
Name:List Should Not Contain DuplicatesSource:Collections <test library>Arguments:[ list_ | ms ...
- 【RF库Collections测试】lists should be equal
场景一:msg=None 场景二:自定义msg 场景三:自定义msg和values,且values为布尔类型False或者字符串False和No Values 场景四:自定义msg和values,且v ...
随机推荐
- Kafka设计解析(二):Kafka High Availability (上)
转自:http://www.infoq.com/cn/articles/kafka-analysis-part-2/ Kafka在0.8以前的版本中,并不提供High Availablity机制,一旦 ...
- VISUAL STUDIO 2012下的OPENCV 2.4.7安装过程
邮箱已经收到了Visual Studio 2013的升级通知,但是很多软件如OpenCV.Qt等都只有VS2012的预编译库,还是懒得升级了(除非VS支持C++11了). 网上搜了一些VS2012(或 ...
- activity 与 fragment生命周期
一.Activity的生命周期图: 二.Fragment生命周期图 三.对比图 Log数据 Activity﹕ onCreateFragment﹕ onAttachFragment﹕ onCre ...
- 产品需求文档 PRD
第一轮: 1,文档使用方:UI设计师 2.内容: 根据战略层定义出来产品功能范围, 说明此产品的目的,方便UI设计人员更好的理解产品 产品基本流程 详细 ...
- Python——uuid
uuid模块在Python 2.5以后引入,接口包括:不可变对象UUID(UUID类)和函数uuid1().uuid3().uuid4()和uuid5(),后面的四个函数用于生成 RFC 4122 规 ...
- C# Http访问帮助类,支持get post请求文件下载 [
using System; using System.Collections.Generic; using System.Collections.Specialized; using System.I ...
- Dubbo+Zookeeper+Spring整合应用篇-Dubbo基于Zookeeper实现分布式服务(转)
Dubbo与Zookeeper.Spring整合使用 Dubbo采用全Spring配置方式,透明化接入应用,对应用没有任何API侵入,只需用Spring加载Dubbo的配置即可,Dubbo基于Spri ...
- linux command not found错误提示
错误提示:screen: command not found, 如果提示screen: command not found 命令不存在可以执行:yum install screen 或 apt-get ...
- 使用 CGContextRef 进行简单内容绘制
摘要 : CGContextRef 功能强大,我们借助它可以画各种图形.这里所举例子只是简单内容绘制,冰山一角,对此感兴趣的朋友可以举一反三,实现各种酷炫效果. 效果如下: KMDrawView.h ...
- tftp
Ubuntu 12.04 tftp 设置 1.sudo apt-get install tftp-hpa tftpd-hpa 2.修改/etc/default/tftpd-hpa TFTP_USERN ...