digital-ai-testing-mcp 2.0.9 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (133) hide show
  1. package/README.md +27 -31
  2. package/dist/api/client.d.ts +3 -3
  3. package/dist/api/client.js +4 -4
  4. package/dist/api/client.js.map +1 -1
  5. package/dist/api/projects.js +1 -1
  6. package/dist/api/projects.js.map +1 -1
  7. package/dist/api/reporting.d.ts +6 -1
  8. package/dist/api/reporting.d.ts.map +1 -1
  9. package/dist/api/reporting.js +45 -12
  10. package/dist/api/reporting.js.map +1 -1
  11. package/dist/api/repository.d.ts +8 -0
  12. package/dist/api/repository.d.ts.map +1 -1
  13. package/dist/api/repository.js +20 -9
  14. package/dist/api/repository.js.map +1 -1
  15. package/dist/api/test-requests.d.ts +25 -0
  16. package/dist/api/test-requests.d.ts.map +1 -0
  17. package/dist/api/test-requests.js +40 -0
  18. package/dist/api/test-requests.js.map +1 -0
  19. package/dist/api/usage-reports.d.ts +7 -4
  20. package/dist/api/usage-reports.d.ts.map +1 -1
  21. package/dist/api/usage-reports.js +7 -4
  22. package/dist/api/usage-reports.js.map +1 -1
  23. package/dist/api/virtual-devices.d.ts +37 -0
  24. package/dist/api/virtual-devices.d.ts.map +1 -0
  25. package/dist/api/virtual-devices.js +69 -0
  26. package/dist/api/virtual-devices.js.map +1 -0
  27. package/dist/api/webdriver.d.ts +47 -1
  28. package/dist/api/webdriver.d.ts.map +1 -1
  29. package/dist/api/webdriver.js +157 -13
  30. package/dist/api/webdriver.js.map +1 -1
  31. package/dist/index.js +7 -4
  32. package/dist/index.js.map +1 -1
  33. package/dist/tools/boilerplate-tools.d.ts +9 -0
  34. package/dist/tools/boilerplate-tools.d.ts.map +1 -1
  35. package/dist/tools/boilerplate-tools.js +347 -61
  36. package/dist/tools/boilerplate-tools.js.map +1 -1
  37. package/dist/tools/device-health-tool.d.ts +3 -0
  38. package/dist/tools/device-health-tool.d.ts.map +1 -0
  39. package/dist/tools/device-health-tool.js +175 -0
  40. package/dist/tools/device-health-tool.js.map +1 -0
  41. package/dist/tools/device-tools.d.ts +2 -0
  42. package/dist/tools/device-tools.d.ts.map +1 -1
  43. package/dist/tools/device-tools.js +67 -6
  44. package/dist/tools/device-tools.js.map +1 -1
  45. package/dist/tools/health-tools.d.ts.map +1 -1
  46. package/dist/tools/health-tools.js +3 -0
  47. package/dist/tools/health-tools.js.map +1 -1
  48. package/dist/tools/inspection-tools.d.ts.map +1 -1
  49. package/dist/tools/inspection-tools.js +41 -2
  50. package/dist/tools/inspection-tools.js.map +1 -1
  51. package/dist/tools/meta-tools.d.ts +1 -1
  52. package/dist/tools/meta-tools.d.ts.map +1 -1
  53. package/dist/tools/meta-tools.js +4 -4
  54. package/dist/tools/meta-tools.js.map +1 -1
  55. package/dist/tools/remediation-tools.js +1 -1
  56. package/dist/tools/remediation-tools.js.map +1 -1
  57. package/dist/tools/reporting-tools.d.ts.map +1 -1
  58. package/dist/tools/reporting-tools.js +79 -21
  59. package/dist/tools/reporting-tools.js.map +1 -1
  60. package/dist/tools/repository-tools.js +3 -3
  61. package/dist/tools/repository-tools.js.map +1 -1
  62. package/dist/tools/resources.js +3 -3
  63. package/dist/tools/resources.js.map +1 -1
  64. package/dist/tools/usage-report-tools.js +1 -1
  65. package/dist/tools/usage-report-tools.js.map +1 -1
  66. package/dist/types/digital-ai.d.ts +2 -0
  67. package/dist/types/digital-ai.d.ts.map +1 -1
  68. package/dist/utils/access-level.d.ts +1 -1
  69. package/dist/utils/access-level.d.ts.map +1 -1
  70. package/dist/utils/api-error.js +1 -1
  71. package/dist/utils/api-error.js.map +1 -1
  72. package/dist/utils/device-health.d.ts +52 -0
  73. package/dist/utils/device-health.d.ts.map +1 -0
  74. package/dist/utils/device-health.js +76 -0
  75. package/dist/utils/device-health.js.map +1 -0
  76. package/dist/utils/device-query.d.ts +6 -0
  77. package/dist/utils/device-query.d.ts.map +1 -0
  78. package/dist/utils/device-query.js +10 -0
  79. package/dist/utils/device-query.js.map +1 -0
  80. package/dist/utils/device-resolver.d.ts.map +1 -1
  81. package/dist/utils/device-resolver.js +2 -1
  82. package/dist/utils/device-resolver.js.map +1 -1
  83. package/dist/utils/download-command.d.ts +1 -1
  84. package/dist/utils/download-command.d.ts.map +1 -1
  85. package/dist/utils/log-view.d.ts +30 -0
  86. package/dist/utils/log-view.d.ts.map +1 -0
  87. package/dist/utils/log-view.js +84 -0
  88. package/dist/utils/log-view.js.map +1 -0
  89. package/dist/utils/path-guard.js +1 -1
  90. package/dist/utils/path-guard.js.map +1 -1
  91. package/dist/utils/performance-comparison.d.ts +1 -1
  92. package/dist/utils/performance-comparison.d.ts.map +1 -1
  93. package/dist/utils/performance-comparison.js +3 -2
  94. package/dist/utils/performance-comparison.js.map +1 -1
  95. package/dist/utils/performance-stats.js +2 -2
  96. package/dist/utils/performance-stats.js.map +1 -1
  97. package/dist/utils/remediation.d.ts +14 -6
  98. package/dist/utils/remediation.d.ts.map +1 -1
  99. package/dist/utils/remediation.js +31 -15
  100. package/dist/utils/remediation.js.map +1 -1
  101. package/dist/utils/test-orchestrator.d.ts +1 -1
  102. package/dist/utils/test-orchestrator.d.ts.map +1 -1
  103. package/dist/utils/test-orchestrator.js +2 -1
  104. package/dist/utils/test-orchestrator.js.map +1 -1
  105. package/dist/utils/tool-annotations.d.ts +5 -0
  106. package/dist/utils/tool-annotations.d.ts.map +1 -1
  107. package/dist/utils/tool-annotations.js +6 -1
  108. package/dist/utils/tool-annotations.js.map +1 -1
  109. package/dist/utils/tool-registry.d.ts +2 -1
  110. package/dist/utils/tool-registry.d.ts.map +1 -1
  111. package/dist/utils/tool-registry.js +2 -1
  112. package/dist/utils/tool-registry.js.map +1 -1
  113. package/dist/utils/toolsets.d.ts +3 -3
  114. package/dist/utils/toolsets.d.ts.map +1 -1
  115. package/dist/utils/toolsets.js +6 -1
  116. package/dist/utils/toolsets.js.map +1 -1
  117. package/dist/utils/upload-command.d.ts +1 -1
  118. package/dist/utils/upload-command.d.ts.map +1 -1
  119. package/dist/utils/usage-report-summary.d.ts +4 -4
  120. package/dist/utils/usage-report-summary.d.ts.map +1 -1
  121. package/dist/utils/usage-report-summary.js +4 -4
  122. package/dist/utils/usage-report-summary.js.map +1 -1
  123. package/dist/utils/version.js +1 -1
  124. package/dist/utils/version.js.map +1 -1
  125. package/package.json +6 -1
  126. package/resources/boilerplate/Android-Native/NodeJS (WebDriver)/wdio-oss.conf.js +2 -2
  127. package/resources/boilerplate/Android-Native/Robot Framework/AndroidNative-oss.robot +51 -0
  128. package/resources/boilerplate/Android-Native/Robot Framework/DigitalAiReport.py +36 -0
  129. package/resources/boilerplate/Android-Native/Robot Framework/pip-oss.txt +2 -0
  130. package/resources/boilerplate/Web/Robot Framework/DigitalAiWebReport.py +36 -0
  131. package/resources/boilerplate/iOS-Native/Robot Framework/DigitalAiReport.py +36 -0
  132. package/resources/boilerplate/iOS-Native/Robot Framework/iOSNative-oss.robot +49 -0
  133. package/resources/boilerplate/iOS-Native/Robot Framework/pip-oss.txt +2 -0
@@ -0,0 +1,51 @@
1
+ *** Settings ***
2
+ Documentation Digital.ai Testing — Android native test (Appium Server project), generated by the Digital.ai Testing MCP.
3
+ ... Run: pip install -r requirements.txt then robot tests/AndroidNative.robot
4
+ Library AppiumLibrary timeout=10
5
+ Library DigitalAiReport.py
6
+ Test Setup Open Cloud Session
7
+ Test Teardown Close Cloud Session
8
+
9
+ *** Variables ***
10
+ ${REMOTE_URL} [Enter Instance here]/wd/hub
11
+ # The DIGITAL_AI_ACCESS_KEY environment variable wins; the value after "=" is the fallback. Remove the fallback before committing.
12
+ ${ACCESS_KEY} %{DIGITAL_AI_ACCESS_KEY=[Enter Your Access key here]}
13
+ ${TEST_NAME} [Enter Test Name here]
14
+ &{CAPABILITIES} platformName=Android
15
+ ... appium:automationName=UiAutomator2
16
+ ... digitalai:accessKey=${ACCESS_KEY}
17
+ ... digitalai:testName=${TEST_NAME}
18
+ ... digitalai:deviceQuery=@os='android' and @category='[Enter PHONE/TABLET here]'
19
+ ... appium:app=cloud:com.experitest.ExperiBank/.LoginActivity
20
+ ... appium:appPackage=com.experitest.ExperiBank
21
+ ... appium:appActivity=.LoginActivity
22
+ ... appium:autoGrantPermissions=${True}
23
+
24
+ *** Test Cases ***
25
+ Quick Start Android Native Demo
26
+ Start Steps Group Test steps
27
+ # [BEGIN_DEMO_STEPS]
28
+ Input Text id=com.experitest.ExperiBank:id/usernameTextField company
29
+ Input Text id=com.experitest.ExperiBank:id/passwordTextField company
30
+ Click Element id=com.experitest.ExperiBank:id/loginButton
31
+ Click Element id=com.experitest.ExperiBank:id/makePaymentButton
32
+ Input Text id=com.experitest.ExperiBank:id/phoneTextField 0501234567
33
+ Input Text id=com.experitest.ExperiBank:id/nameTextField John Snow
34
+ Input Text id=com.experitest.ExperiBank:id/amountTextField 50
35
+ Click Element xpath=//*[@resource-id='com.experitest.ExperiBank:id/countryButton']
36
+ Click Element xpath=//*[@text='Switzerland']
37
+ Click Element id=com.experitest.ExperiBank:id/sendPaymentButton
38
+ Click Element id=android:id/button1
39
+ # [END_DEMO_STEPS]
40
+ Stop Steps Group
41
+
42
+ *** Keywords ***
43
+ Open Cloud Session
44
+ Open Application ${REMOTE_URL} &{CAPABILITIES}
45
+
46
+ Close Cloud Session
47
+ # Report the real outcome: without this a failed step or assertion can still show as Passed in the platform report.
48
+ Run Keyword And Ignore Error Report Test Outcome ${TEST STATUS} ${TEST MESSAGE}
49
+ ${url}= Run Keyword And Ignore Error Get Capability digitalai:reportUrl
50
+ Log To Console \nReport URL: ${url}[1]
51
+ Close Application
@@ -0,0 +1,36 @@
1
+ """Digital.ai platform-report keywords for Robot Framework + AppiumLibrary (generated by the Digital.ai Testing MCP).
2
+
3
+ seetest:client commands take their arguments as separate execute_script parameters — the inline form
4
+ ("seetest:client.report('x')") is not reliable. Appium Server sessions only.
5
+ """
6
+ from robot.libraries.BuiltIn import BuiltIn
7
+
8
+
9
+ class DigitalAiReport:
10
+ ROBOT_LIBRARY_SCOPE = 'TEST'
11
+
12
+ def __init__(self):
13
+ self._group_open = False
14
+
15
+ def _driver(self):
16
+ return BuiltIn().get_library_instance('AppiumLibrary')._current_application()
17
+
18
+ def start_steps_group(self, name):
19
+ """Open a named steps group in the platform report."""
20
+ self._driver().execute_script('seetest:client.startStepsGroup', name)
21
+ self._group_open = True
22
+
23
+ def stop_steps_group(self):
24
+ """Close the open steps group (no-op when none is open)."""
25
+ if self._group_open:
26
+ self._driver().execute_script('seetest:client.stopStepsGroup')
27
+ self._group_open = False
28
+
29
+ def report_step(self, message, passed=True):
30
+ """Add a step to the platform report."""
31
+ self._driver().execute_script('seetest:client.report', message, 'true' if passed else 'false')
32
+
33
+ def report_test_outcome(self, status, message=''):
34
+ """Set the platform report status from Robot's ${TEST STATUS}: PASS → Passed, SKIP → Skipped, else Failed."""
35
+ mapped = {'PASS': 'Passed', 'SKIP': 'Skipped'}.get(str(status).upper(), 'Failed')
36
+ self._driver().execute_script('seetest:client.setReportStatus', mapped, (message or 'All steps completed')[:500])
@@ -0,0 +1,2 @@
1
+ robotframework==7.5
2
+ robotframework-appiumlibrary==3.2.1
@@ -0,0 +1,36 @@
1
+ """Digital.ai platform-report keywords for Robot Framework + SeleniumLibrary (generated by the Digital.ai Testing MCP).
2
+
3
+ seetest:client commands take their arguments as separate execute_script parameters; the Digital.ai Selenium Grid
4
+ forwards them to the reporter (verified live: "successfully sent to reporter").
5
+ """
6
+ from robot.libraries.BuiltIn import BuiltIn
7
+
8
+
9
+ class DigitalAiWebReport:
10
+ ROBOT_LIBRARY_SCOPE = 'TEST'
11
+
12
+ def __init__(self):
13
+ self._group_open = False
14
+
15
+ def _driver(self):
16
+ return BuiltIn().get_library_instance('SeleniumLibrary').driver
17
+
18
+ def start_steps_group(self, name):
19
+ """Open a named steps group in the platform report."""
20
+ self._driver().execute_script('seetest:client.startStepsGroup', name)
21
+ self._group_open = True
22
+
23
+ def stop_steps_group(self):
24
+ """Close the open steps group (no-op when none is open)."""
25
+ if self._group_open:
26
+ self._driver().execute_script('seetest:client.stopStepsGroup')
27
+ self._group_open = False
28
+
29
+ def report_step(self, message, passed=True):
30
+ """Add a step to the platform report."""
31
+ self._driver().execute_script('seetest:client.report', message, 'true' if passed else 'false')
32
+
33
+ def report_test_outcome(self, status, message=''):
34
+ """Set the platform report status from Robot's ${TEST STATUS}: PASS → Passed, SKIP → Skipped, else Failed."""
35
+ mapped = {'PASS': 'Passed', 'SKIP': 'Skipped'}.get(str(status).upper(), 'Failed')
36
+ self._driver().execute_script('seetest:client.setReportStatus', mapped, (message or 'All steps completed')[:500])
@@ -0,0 +1,36 @@
1
+ """Digital.ai platform-report keywords for Robot Framework + AppiumLibrary (generated by the Digital.ai Testing MCP).
2
+
3
+ seetest:client commands take their arguments as separate execute_script parameters — the inline form
4
+ ("seetest:client.report('x')") is not reliable. Appium Server sessions only.
5
+ """
6
+ from robot.libraries.BuiltIn import BuiltIn
7
+
8
+
9
+ class DigitalAiReport:
10
+ ROBOT_LIBRARY_SCOPE = 'TEST'
11
+
12
+ def __init__(self):
13
+ self._group_open = False
14
+
15
+ def _driver(self):
16
+ return BuiltIn().get_library_instance('AppiumLibrary')._current_application()
17
+
18
+ def start_steps_group(self, name):
19
+ """Open a named steps group in the platform report."""
20
+ self._driver().execute_script('seetest:client.startStepsGroup', name)
21
+ self._group_open = True
22
+
23
+ def stop_steps_group(self):
24
+ """Close the open steps group (no-op when none is open)."""
25
+ if self._group_open:
26
+ self._driver().execute_script('seetest:client.stopStepsGroup')
27
+ self._group_open = False
28
+
29
+ def report_step(self, message, passed=True):
30
+ """Add a step to the platform report."""
31
+ self._driver().execute_script('seetest:client.report', message, 'true' if passed else 'false')
32
+
33
+ def report_test_outcome(self, status, message=''):
34
+ """Set the platform report status from Robot's ${TEST STATUS}: PASS → Passed, SKIP → Skipped, else Failed."""
35
+ mapped = {'PASS': 'Passed', 'SKIP': 'Skipped'}.get(str(status).upper(), 'Failed')
36
+ self._driver().execute_script('seetest:client.setReportStatus', mapped, (message or 'All steps completed')[:500])
@@ -0,0 +1,49 @@
1
+ *** Settings ***
2
+ Documentation Digital.ai Testing — iOS native test (Appium Server project), generated by the Digital.ai Testing MCP.
3
+ ... Run: pip install -r requirements.txt then robot tests/iOSNative.robot
4
+ Library AppiumLibrary timeout=10
5
+ Library DigitalAiReport.py
6
+ Test Setup Open Cloud Session
7
+ Test Teardown Close Cloud Session
8
+
9
+ *** Variables ***
10
+ ${REMOTE_URL} [Enter Instance here]/wd/hub
11
+ # The DIGITAL_AI_ACCESS_KEY environment variable wins; the value after "=" is the fallback. Remove the fallback before committing.
12
+ ${ACCESS_KEY} %{DIGITAL_AI_ACCESS_KEY=[Enter Your Access key here]}
13
+ ${TEST_NAME} [Enter Test Name here]
14
+ &{CAPABILITIES} platformName=iOS
15
+ ... appium:automationName=XCUITest
16
+ ... digitalai:accessKey=${ACCESS_KEY}
17
+ ... digitalai:testName=${TEST_NAME}
18
+ ... digitalai:deviceQuery=@os='ios' and @category='[Enter PHONE/TABLET here]'
19
+ ... appium:app=cloud:com.experitest.ExperiBank
20
+ ... appium:bundleId=com.experitest.ExperiBank
21
+
22
+ *** Test Cases ***
23
+ Quick Start iOS Native Demo
24
+ Start Steps Group Test steps
25
+ # [BEGIN_DEMO_STEPS]
26
+ Input Text xpath=//*[@name='usernameTextField'] company
27
+ Input Text xpath=//*[@name='passwordTextField'] company
28
+ Click Element xpath=//*[@name='loginButton']
29
+ Click Element xpath=//*[@name='makePaymentButton']
30
+ Input Text xpath=//*[@name='phoneTextField'] 1234567
31
+ Input Text xpath=//*[@name='nameTextField'] Jon Snow
32
+ Input Text xpath=//*[@name='amountTextField'] 50
33
+ Click Element xpath=//*[@name='countryButton']
34
+ Click Element xpath=//*[@name='Switzerland']
35
+ Click Element xpath=//*[@name='sendPaymentButton']
36
+ Click Element xpath=//*[@name='Yes']
37
+ # [END_DEMO_STEPS]
38
+ Stop Steps Group
39
+
40
+ *** Keywords ***
41
+ Open Cloud Session
42
+ Open Application ${REMOTE_URL} &{CAPABILITIES}
43
+
44
+ Close Cloud Session
45
+ # Report the real outcome: without this a failed step or assertion can still show as Passed in the platform report.
46
+ Run Keyword And Ignore Error Report Test Outcome ${TEST STATUS} ${TEST MESSAGE}
47
+ ${url}= Run Keyword And Ignore Error Get Capability digitalai:reportUrl
48
+ Log To Console \nReport URL: ${url}[1]
49
+ Close Application
@@ -0,0 +1,2 @@
1
+ robotframework==7.5
2
+ robotframework-appiumlibrary==3.2.1