diff --git a/docs/how_to_use.rst b/docs/how_to_use.rst index 0715edb53..72d3dbbcb 100644 --- a/docs/how_to_use.rst +++ b/docs/how_to_use.rst @@ -6,6 +6,7 @@ Prerequisites * :code:`globalConfig.json` * :code:`package` folder +* :code:`git` for automatic versioning (when no :code:`ta-version` argument is specified) Example of :code:`globalConfig.json` and :code:`package` folder can be found at https://github.com/splunk/splunk-add-on-for-ucc-example. diff --git a/tests/data/globalConfig.json b/tests/data/globalConfig.json index 0ffcfbc27..0b00a493f 100644 --- a/tests/data/globalConfig.json +++ b/tests/data/globalConfig.json @@ -94,7 +94,8 @@ "help": "This is an example radio button for the account entity", "required": true, "options": { - "items": [{ + "items": [ + { "value": "yes", "label": "Yes" }, @@ -113,7 +114,8 @@ "help": "This is an example multipleSelect for account entity", "required": true, "options": { - "items": [{ + "items": [ + { "value": "one", "label": "Option One" }, @@ -124,15 +126,6 @@ ] } }, - { - "type": "text", - "label": "State", - "help": "This is a boolean field for developers to decide whether state parameter will be passed in the OAuth flow. Value: true|false", - "field": "oauth_state_enabled", - "options": { - "display": false - } - }, { "type": "oauth", "field": "oauth", @@ -187,7 +180,8 @@ ], "auth_code_endpoint": "/services/oauth2/authorize", "access_token_endpoint": "/services/oauth2/token", - "oauth_timeout": 30 + "oauth_timeout": 30, + "oauth_state_enabled": false } }, { @@ -465,7 +459,8 @@ "help": "This is an example radio button for the input one entity", "required": false, "options": { - "items": [{ + "items": [ + { "value": "yes", "label": "Yes" }, @@ -759,7 +754,8 @@ "help": "This is an example multipleSelect for input two entity", "required": true, "options": { - "items": [{ + "items": [ + { "value": "one", "label": "Option One" }, @@ -784,7 +780,8 @@ "help": "This is an example radio button for the input two entity", "required": false, "options": { - "items": [{ + "items": [ + { "value": "yes", "label": "Yes" }, @@ -1029,7 +1026,8 @@ "apiVersion": "3.2.0", "name": "Splunk_TA_UCCExample", "restRoot": "splunk_ta_uccexample", - "version": "1.0.0", - "displayName": "Splunk UCC test Add-on" + "version": "5.0.0de0f47df5", + "displayName": "Splunk UCC test Add-on", + "schemaVersion": "0.0.2" } -} +} \ No newline at end of file diff --git a/tests/data/test_ucc_generate.py b/tests/data/test_ucc_generate.py new file mode 100644 index 000000000..08cb8de15 --- /dev/null +++ b/tests/data/test_ucc_generate.py @@ -0,0 +1,14 @@ +from os import path +import unittest + +import splunk_add_on_ucc_framework as ucc + + +class UccGenerateTest(unittest.TestCase): + def test_ucc_generate_without_arguments(self): + package_folder = path.join(path.dirname(path.realpath(__file__)), "package") + ucc.generate(source=package_folder) + + +if __name__ == "__main__": + unittest.main()