Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am Tattoo on github.
  • I am tattoo (https://keybase.io/tattoo) on keybase.
  • I have a public key whose fingerprint is B755 BD26 BEA9 7156 F431 2CA8 26A8 BE39 3C12 328E

To claim this, I am signing this object:

### First we have pure Robot Framework implementation:
## manualtestdata.robot
*** Settings ***
Library Dialogs
*** Keywords ***
Manually enter test data
/*
USAGE: open 'Developer Tools', open 'Console', copy-paste everything.
*/
/* First add missing interface for evaluating XPath expressions.
This is from wicked-good-xpath https://code.google.com/p/wicked-good-xpath/
*/
class ArgumentConversionException(Exception):
pass
def _validate(args, conversions):
args_len, conversions_len = len(args), len(conversions)
msg = None
if args_len < conversions_len:
msg = ('Too many conversion functions given: %d arguments given when '
'%d conversions got.' % (args_len, conversions_len))
import sys
from robot.api import ExecutionResult, ResultVisitor
from robot.result.keyword import Keyword
from robot.result.testsuite import TestSuite
class dotdict(dict):
def __getattr__(self, attr_name):
return self[attr_name]
def __setattr__(self, attr_name, value):
*** Test cases ***
TEST CASE
No Operation
No Operation
No Operation
No Operation
No Operation
No Operation
No Operation
@Tattoo
Tattoo / robot_framework_highlight_notepad++.xml
Last active September 22, 2017 07:57
Robot Framework syntax hilighting for Notepad++
<!-- take into use:
Save this file
Open Notepad++
Select menu: Language > Define your language...
You get a popup. Select "Import", navigate to xml-file
Click "Save as" and name your file eg. "RobotFramework"
Now you can open a Robot test suite file and select from Languages -menu the correct language (in the bottom)
-->
<NotepadPlus>
<UserLang name="RobotFramework" ext="txt">
"""translate_lib.py
CLI tool for creating Robot Framework resource file which holds translations for all keywords from a given library.
"""
import codecs
import sys
from robot.libdoc import libdoc
from StringIO import StringIO
def get_kws(lib):
from robot.api import ExecutionResult, ResultVisitor
import re
class KeywordTimes(ResultVisitor):
VAR_PATTERN = re.compile(r'^(\$|\@)\{[^\}]+\}(, \$\{[^\}]+\})* = ')
def __init__(self):
self.keywords = {}