summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMohamed Abdelnour <mohamed.k.abdelnour@gmail.com>2021-05-30 09:11:19 +0200
committerDavid Peter <sharkdp@users.noreply.github.com>2021-06-01 22:36:56 +0200
commit9935c4984c754201fa6192da3d00ae6a95a8ed82 (patch)
tree4cbae0fb70f81a85cde8b5fec2c22c171ffedff7
parenta0a5e30c3961273b16609c566bddb5f802d8279b (diff)
Add Robot Framework syntax test file
-rw-r--r--tests/syntax-tests/highlighted/Robot Framework/recipe141_aws_simple_storage_service.robot31
-rw-r--r--tests/syntax-tests/source/Robot Framework/LICENSE.md25
-rw-r--r--tests/syntax-tests/source/Robot Framework/recipe141_aws_simple_storage_service.robot31
3 files changed, 87 insertions, 0 deletions
diff --git a/tests/syntax-tests/highlighted/Robot Framework/recipe141_aws_simple_storage_service.robot b/tests/syntax-tests/highlighted/Robot Framework/recipe141_aws_simple_storage_service.robot
new file mode 100644
index 00000000..6f22031a
--- /dev/null
+++ b/tests/syntax-tests/highlighted/Robot Framework/recipe141_aws_simple_storage_service.robot
@@ -0,0 +1,31 @@
+*** Settings ***
+Documentation PROBLEM:
+... You want to test the existence of a file in an AWS S3 bucket
+... without using lower level Python code or developing a custom library.
+... DISCUSSION:
+... This recipe demonstrates:
+... - using a Suite Teardown to end the test suite cleanly
+... - using keywords from an external library
+... - accessing OS Environment Variables directly using %{} syntax
+... This recipe has the following external dependencies:
+... $ pip install --upgrade robotframework-aws
+... This recipe also requires the following OS environment variables:
+... AWS_ACCESS_KEY_ID
+... AWS_SECRET_ACCESS_KEY
+Suite Teardown  Delete All Sessions
+Library  AWSLibrary
+Force Tags  no-ci-testing
+
+*** Variables ***
+${recipe} Recipe 14.1 AWS Simple Storage Service
+${level} Intermediate
+${category} External Library: AWSLibrary
+${REGION} us-east-1
+${BUCKET} YOUR_BUCKET_NAME_GOES_HERE
+${KEY} YOUR_FILE_PATH_GOES_HERE
+
+*** Test Cases ***
+Check Key Exists In Bucket
+ Log Variables
+ Create Session With Keys ${REGION} %{AWS_ACCESS_KEY_ID} %{AWS_SECRET_ACCESS_KEY}
+ Key Should Exist ${BUCKET} ${KEY}
diff --git a/tests/syntax-tests/source/Robot Framework/LICENSE.md b/tests/syntax-tests/source/Robot Framework/LICENSE.md
new file mode 100644
index 00000000..59741cee
--- /dev/null
+++ b/tests/syntax-tests/source/Robot Framework/LICENSE.md
@@ -0,0 +1,25 @@
+The `recipe141_aws_simple_storage_service.robot` file has been added from https://github.com/adrianyorke/robotframework-cookbook under the following license:
+
+```text
+MIT License
+
+Copyright (c) 2020 Adrian Yorke
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+```
diff --git a/tests/syntax-tests/source/Robot Framework/recipe141_aws_simple_storage_service.robot b/tests/syntax-tests/source/Robot Framework/recipe141_aws_simple_storage_service.robot
new file mode 100644
index 00000000..2c446b40
--- /dev/null
+++ b/tests/syntax-tests/source/Robot Framework/recipe141_aws_simple_storage_service.robot
@@ -0,0 +1,31 @@
+*** Settings ***
+Documentation PROBLEM:
+... You want to test the existence of a file in an AWS S3 bucket
+... without using lower level Python code or developing a custom library.
+... DISCUSSION:
+... This recipe demonstrates:
+... - using a Suite Teardown to end the test suite cleanly
+... - using keywords from an external library
+... - accessing OS Environment Variables directly using %{} syntax
+... This recipe has the following external dependencies:
+... $ pip install --upgrade robotframework-aws
+... This recipe also requires the following OS environment variables:
+... AWS_ACCESS_KEY_ID
+... AWS_SECRET_ACCESS_KEY
+Suite Teardown Delete All Sessions
+Library AWSLibrary
+Force Tags no-ci-testing
+
+*** Variables ***
+${recipe} Recipe 14.1 AWS Simple Storage Service
+${level} Intermediate
+${category} External Library: AWSLibrary
+${REGION} us-east-1
+${BUCKET} YOUR_BUCKET_NAME_GOES_HERE
+${KEY} YOUR_FILE_PATH_GOES_HERE
+
+*** Test Cases ***
+Check Key Exists In Bucket
+ Log Variables
+ Create Session With Keys ${REGION} %{AWS_ACCESS_KEY_ID} %{AWS_SECRET_ACCESS_KEY}
+ Key Should Exist ${BUCKET} ${KEY}