CSV library for robotframework written in Python 3
Project description
robotframework-csvlib
CSV library for robotframework written in Python 3
Installation
pip install robotframework-csvlib
Quick Keyword Overview
Read CSV As Single List
Arguments:
Filepath
Delimiter (optional)
Returns:
A single list with all values.
Read CSV As List
Arguments:
Filepath
Delimiter (optional)
Returns:
A list containing all rows as lists.
Read CSV As Dictionary
Arguments:
Filepath
Name of key column
Name(s) of value column(s)
Delimiter (optional)
Returns:
A dictionary with the key column a key and the value column(s) as value.
If there are multiple value columns the value will be a list containing all values.
Example
*** Settings ***
Library CSVLib
*** Test Cases ***
Test CSV
${singlelist}= Read CSV As Single List test.csv
log to console ${singlelist}
${list}= read csv as list test.csv
log to console ${list}
${dict}= read csv as dictionary test_dict.csv Animal Legs ,
log to console ${dict}
${value}= create list Legs Eyes
${dictWList}= read csv as dictionary test_dict1.csv Animal ${value} ,
log to console ${dictWList}
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
Built Distribution
Close
Hashes for robotframework-csvlib-1.0.2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | e5d5568660d6da7d8e3941c18379fb5bee389f6ab36eee6a40b87be1f6273fa4 |
|
MD5 | bd6b53defdb58620f9ed376edff11230 |
|
BLAKE2b-256 | 135924d26b5a54c24463f42faea198c9f860492d1a17c9c1e70c33f26550f5d3 |
Close
Hashes for robotframework_csvlib-1.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 793c17495dad08ab77ef58ef47ef82ece47c7f25a9156db506783fcb269a641d |
|
MD5 | 294499eea58d0d5fe2d98db7e92683f6 |
|
BLAKE2b-256 | def6116a67197c356c4cc4f5c4435784b10b6544a8e3e43b59553cdae49d85d8 |