Module: TestingBot::Resources::Tests
- Included in:
- Api
- Defined in:
- lib/testingbot/resources/tests.rb
Overview
Endpoints under /tests.
Instance Method Summary collapse
- #delete_test(test_id) ⇒ Object
- #get_test(test_id) ⇒ Object
-
#get_tests(offset = 0, count = 10, filters = {}) ⇒ Object
filtersaccepts the backend’s optional query params: since, browser_id, group, build, skip_fields. - #stop_test(test_id) ⇒ Object
- #update_test(test_id, params = {}) ⇒ Object
Instance Method Details
#delete_test(test_id) ⇒ Object
19 20 21 |
# File 'lib/testingbot/resources/tests.rb', line 19 def delete_test(test_id) success?(delete("/tests/#{escape(test_id)}")) end |
#get_test(test_id) ⇒ Object
11 12 13 |
# File 'lib/testingbot/resources/tests.rb', line 11 def get_test(test_id) get("/tests/#{escape(test_id)}") end |
#get_tests(offset = 0, count = 10, filters = {}) ⇒ Object
filters accepts the backend’s optional query params: since, browser_id, group, build, skip_fields.
7 8 9 |
# File 'lib/testingbot/resources/tests.rb', line 7 def get_tests(offset = 0, count = 10, filters = {}) get("/tests#{query({ :offset => offset, :count => count }.merge(filters))}") end |
#stop_test(test_id) ⇒ Object
23 24 25 |
# File 'lib/testingbot/resources/tests.rb', line 23 def stop_test(test_id) success?(put("/tests/#{escape(test_id)}/stop")) end |
#update_test(test_id, params = {}) ⇒ Object
15 16 17 |
# File 'lib/testingbot/resources/tests.rb', line 15 def update_test(test_id, params = {}) success?(put("/tests/#{escape(test_id)}", wrap_params("test", params))) end |