How to use the apiritif.CSVReaderPerThread function in apiritif

To help you get started, we’ve selected a few apiritif examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Blazemeter / taurus / tests / resources / apiritif / test_data_sources.py View on Github external
# coding=utf-8

import logging
import random
import string
import sys
import unittest
from time import time, sleep

import apiritif

reader_1 = apiritif.CSVReaderPerThread('first-file.csv')
reader_2 = apiritif.CSVReaderPerThread('/second/file.csv', loop=True, quoted=False, delimiter='-')


class TestAPI(unittest.TestCase, ):

    def setUp(self):
        self.target = apiritif.http.target('http://localhost:8000/')
        self.target.keep_alive(True)
        self.target.auto_assert_ok(True)
        self.target.use_cookies(True)
        self.target.allow_redirects(True)
        self.vars = {
            'cn': 'cv'
        }
        reader_1.read_vars()
        reader_2.read_vars()
        self.vars.update(reader_1.get_vars())
github Blazemeter / taurus / tests / resources / apiritif / test_data_sources.py View on Github external
# coding=utf-8

import logging
import random
import string
import sys
import unittest
from time import time, sleep

import apiritif

reader_1 = apiritif.CSVReaderPerThread('first-file.csv')
reader_2 = apiritif.CSVReaderPerThread('/second/file.csv', loop=True, quoted=False, delimiter='-')


class TestAPI(unittest.TestCase, ):

    def setUp(self):
        self.target = apiritif.http.target('http://localhost:8000/')
        self.target.keep_alive(True)
        self.target.auto_assert_ok(True)
        self.target.use_cookies(True)
        self.target.allow_redirects(True)
        self.vars = {
            'cn': 'cv'
        }
        reader_1.read_vars()
        reader_2.read_vars()