summaryrefslogtreecommitdiff
path: root/tests/lexers/robotframework
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2021-01-18 21:24:00 +0100
committerGeorg Brandl <georg@python.org>2021-01-18 22:08:36 +0100
commit2a3d3a7d5b9c60dedf6638d876161d9563faebcf (patch)
tree809c0b4a686db98f5954afa1944404cd9652c6b2 /tests/lexers/robotframework
parentf0445be718da83541ea3401aad882f3937147263 (diff)
downloadpygments-git-examplefiles.tar.gz
Move test_examplefiles to new tests/lexers scheme.examplefiles
Diffstat (limited to 'tests/lexers/robotframework')
-rw-r--r--tests/lexers/robotframework/example.txt264
1 files changed, 264 insertions, 0 deletions
diff --git a/tests/lexers/robotframework/example.txt b/tests/lexers/robotframework/example.txt
new file mode 100644
index 00000000..b6e54c7a
--- /dev/null
+++ b/tests/lexers/robotframework/example.txt
@@ -0,0 +1,264 @@
+---input---
+*** Settings ***
+Documentation Simple example demonstrating syntax highlighting.
+Library ExampleLibrary
+Test Setup Keyword argument argument with ${VARIABLE}
+
+*** Variables ***
+${VARIABLE} Variable value
+@{LIST} List variable here
+&{DICT} Key1=Value1 Key2=Value2
+
+*** Test Cases ***
+Keyword-driven example
+ Initialize System
+ Do Something
+ Result Should Be 42
+ [Teardown] Cleanup System
+
+Data-driven example
+ [Template] Keyword
+ argument1 argument2
+ argument ${VARIABLE}
+ @{LIST}
+
+Gherkin
+ Given system is initialized
+ When something is done
+ Then result should be "42"
+
+| Pipes |
+| | [Documentation] | Also pipe separated format is supported. |
+| | Log | As this example demonstrates. |
+
+*** Keywords ***
+Result Should Be
+ [Arguments] ${expected}
+ ${actual} = Get Value
+ Should be Equal ${actual} ${expected}
+
+Then result should be "${expected}"
+ Result Should Be ${expected}
+
+---tokens---
+'*** Settings ***' Generic.Heading
+'\n' Punctuation
+
+'Documentation' Keyword.Namespace
+' ' Punctuation
+'Simple example demonstrating syntax highlighting.' Literal.String
+'\n' Punctuation
+
+'Library' Keyword.Namespace
+' ' Punctuation
+'ExampleLibrary' Name.Namespace
+'\n' Punctuation
+
+'Test Setup' Keyword.Namespace
+' ' Punctuation
+'Keyword' Name.Function
+' ' Punctuation
+'argument' Literal.String
+' ' Punctuation
+'argument with ' Literal.String
+'${' Punctuation
+'VARIABLE' Name.Variable
+'}' Punctuation
+'\n' Punctuation
+
+'\n' Punctuation
+
+'*** Variables ***' Generic.Heading
+'\n' Punctuation
+
+'${' Punctuation
+'VARIABLE' Name.Variable
+'}' Punctuation
+' ' Punctuation
+'Variable value' Literal.String
+'\n' Punctuation
+
+'@{' Punctuation
+'LIST' Name.Variable
+'}' Punctuation
+' ' Punctuation
+'List' Literal.String
+' ' Punctuation
+'variable' Literal.String
+' ' Punctuation
+'here' Literal.String
+'\n' Punctuation
+
+'&{' Punctuation
+'DICT' Name.Variable
+'}' Punctuation
+' ' Punctuation
+'Key1=Value1' Literal.String
+' ' Punctuation
+'Key2=Value2' Literal.String
+'\n' Punctuation
+
+'\n' Punctuation
+
+'*** Test Cases ***' Generic.Heading
+'\n' Punctuation
+
+'Keyword-driven example' Generic.Subheading
+'\n' Punctuation
+
+' ' Punctuation
+'Initialize System' Name.Function
+'\n' Punctuation
+
+' ' Punctuation
+'Do Something' Name.Function
+'\n' Punctuation
+
+' ' Punctuation
+'Result Should Be' Name.Function
+' ' Punctuation
+'42' Literal.String
+'\n' Punctuation
+
+' ' Punctuation
+'[' Punctuation
+'Teardown' Keyword.Namespace
+']' Punctuation
+' ' Punctuation
+'Cleanup System' Name.Function
+'\n' Punctuation
+
+'\n' Punctuation
+
+'Data-driven example' Generic.Subheading
+'\n' Punctuation
+
+' ' Punctuation
+'[' Punctuation
+'Template' Keyword.Namespace
+']' Punctuation
+' ' Punctuation
+'Keyword' Name.Function
+'\n' Punctuation
+
+' ' Punctuation
+'argument1' Literal.String
+' ' Punctuation
+'argument2' Literal.String
+'\n' Punctuation
+
+' ' Punctuation
+'argument' Literal.String
+' ' Punctuation
+'${' Punctuation
+'VARIABLE' Name.Variable
+'}' Punctuation
+'\n' Punctuation
+
+' ' Punctuation
+'@{' Punctuation
+'LIST' Name.Variable
+'}' Punctuation
+'\n' Punctuation
+
+'\n' Punctuation
+
+'Gherkin' Generic.Subheading
+'\n' Punctuation
+
+' ' Punctuation
+'Given ' Generic.Emph
+'system is initialized' Name.Function
+'\n' Punctuation
+
+' ' Punctuation
+'When ' Generic.Emph
+'something is done' Name.Function
+'\n' Punctuation
+
+' ' Punctuation
+'Then ' Generic.Emph
+'result should be "42"' Name.Function
+'\n' Punctuation
+
+'\n' Punctuation
+
+'| ' Punctuation
+'Pipes' Generic.Subheading
+' |' Punctuation
+'\n' Punctuation
+
+'| ' Punctuation
+'| ' Punctuation
+'[' Punctuation
+'Documentation' Keyword.Namespace
+']' Punctuation
+' | ' Punctuation
+'Also pipe separated format is supported.' Literal.String
+' |' Punctuation
+'\n' Punctuation
+
+'| ' Punctuation
+'| ' Punctuation
+'Log' Name.Function
+' | ' Punctuation
+'As this example demonstrates.' Literal.String
+' |' Punctuation
+'\n' Punctuation
+
+'\n' Punctuation
+
+'*** Keywords ***' Generic.Heading
+'\n' Punctuation
+
+'Result Should Be' Generic.Subheading
+'\n' Punctuation
+
+' ' Punctuation
+'[' Punctuation
+'Arguments' Keyword.Namespace
+']' Punctuation
+' ' Punctuation
+'${' Punctuation
+'expected' Name.Variable
+'}' Punctuation
+'\n' Punctuation
+
+' ' Punctuation
+'${' Punctuation
+'actual' Name.Variable
+'}' Punctuation
+' =' Punctuation
+' ' Punctuation
+'Get Value' Name.Function
+'\n' Punctuation
+
+' ' Punctuation
+'Should be Equal' Name.Function
+' ' Punctuation
+'${' Punctuation
+'actual' Name.Variable
+'}' Punctuation
+' ' Punctuation
+'${' Punctuation
+'expected' Name.Variable
+'}' Punctuation
+'\n' Punctuation
+
+'\n' Punctuation
+
+'Then ' Generic.Emph
+'result should be "' Generic.Subheading
+'${' Punctuation
+'expected' Name.Variable
+'}' Punctuation
+'"' Generic.Subheading
+'\n' Punctuation
+
+' ' Punctuation
+'Result Should Be' Name.Function
+' ' Punctuation
+'${' Punctuation
+'expected' Name.Variable
+'}' Punctuation
+'\n' Punctuation