This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import doctest | |
import subprocess | |
from plone.app.testing import TEST_USER_NAME, TEST_USER_PASSWORD | |
def browser(url, debug=False): | |
def decorator(func): | |
def wrapper(*args): | |
parser = doctest.DocTestParser() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*** Settings *** | |
Documentation A test suite with a single test for valid login. This test has | |
... a workflow that is created using keywords from the resource file. | |
Resource resource.txt | |
*** Test Cases *** | |
Valid Login |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import socket | |
# Sauce only tunnels certain ports, so we need to pick one of those ports and it should be | |
# not used. | |
# See port list at: https://saucelabs.com/docs/connect#localhost | |
PORTS = [2000, 2001, 2020, 2222, 3000, 3001, 3030, 3333, 4000, 4001, 4040, 5000, 5001, 5050, 5555, 6000, 6001, 6060, 6666, 7000, 7070, 7777, 8000, 8001, 8080, 8888, 9000, 9001, 9080, 9090, 9999, 4502, 4503, 8003, 8031] | |
def get_free_port(): | |
for port in PORTS: | |
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*** Settings *** | |
Library Selenium2Library | |
Library String | |
Suite Setup Open browser about: ff_profile_dir=${CURDIR}/profile | |
Suite Teardown Close all browsers | |
*** Test Cases *** |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[buildout] | |
extends = http://dist.plone.org/release/4.3-latest/versions.cfg | |
parts = test | |
[test] | |
recipe = zc.recipe.testrunner | |
eggs = | |
Pillow | |
plone.app.robotframework[speak] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[buildout] | |
extends = http://dist.plone.org/release/4.3-latest/versions.cfg | |
parts = robot | |
versions = versions | |
[robot] | |
recipe = zc.recipe.egg | |
eggs = | |
plone.app.widgets | |
plone.app.robotframework |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
import requests | |
import simplejson as json | |
from robot.api import logger | |
from robot.libraries.BuiltIn import BuiltIn | |
USERNAME_ACCESS_KEY = re.compile('^(http|https):\/\/([^:]+):([^@]+)@') | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import StringIO | |
import threading | |
from zope.interface import implements | |
from ZPublisher.Iterators import IStreamIterator | |
from ZServer.PubCore.ZEvent import Wakeup | |
from zope.globalrequest import getRequest | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### | |
# Simple 'nix-exec' shebang wrapper for using nix-expression as 'standalone' | |
# execs (outside NixOS, e.g. on OSX) without installing them with 'nix-env'. | |
# | |
# The original use case was to replace Python virtualenvs with nix expressions | |
# in Python development. | |
# | |
# Install: | |
# | |
# $ nix-env -i -f datakurre-nix-exec.nix |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
from pyramid_workflow import ( | |
Workflow, | |
get_workflow | |
) | |
def incoming_start(context, request, transition, workflow): | |
pass |
OlderNewer