Module: Wisp
- Defined in:
- lib/wisp-schema.rb,
lib/version.rb
Overview
Provides factory methods that will return the correct schemer instance to use
Defined Under Namespace
Classes: NotSupportedAction
Constant Summary
collapse
- VERSION =
"1.23.0"
- STABLE_VERSION =
"1.23.0"
- SCHEMA_PATH =
File.expand_path("../wisp.json", __dir__)
- NOUNS_PATH =
File.expand_path("../nouns.json", __dir__)
- ACTIONS =
[
"ai_confirmation",
"click",
"close_tab",
"comment",
"conditional_observe",
"double_click",
"download_file",
"drag_and_drop",
"fill",
"generate_steps",
"hover",
"navigate",
"observe",
"press_and_click",
"refresh",
"scroll",
"select",
"send_key",
"snippet",
"store_value",
"tester_confirmation",
"tester_instruction",
"triple_click",
"type",
"wait",
].freeze
Class Method Summary
collapse
Class Method Details
.action_schemer(action) ⇒ Object
54
55
56
57
58
|
# File 'lib/wisp-schema.rb', line 54
def action_schemer(action)
raise NotSupportedAction unless ACTIONS.include?(action)
JSONSchemer.schema(Pathname.new(File.expand_path("../stable/actions/#{action}.json", __dir__)))
end
|
.embedded_test_schemer ⇒ Object
66
67
68
|
# File 'lib/wisp-schema.rb', line 66
def embedded_test_schemer
JSONSchemer.schema(Pathname.new(File.expand_path("../stable/embeddings/embedded_test.json", __dir__)))
end
|
.nouns_schemer ⇒ Object
49
50
51
|
# File 'lib/wisp-schema.rb', line 49
def nouns_schemer
JSONSchemer.schema(Pathname.new(Wisp::NOUNS_PATH))
end
|
.verbs_schemer ⇒ Object
61
62
63
|
# File 'lib/wisp-schema.rb', line 61
def verbs_schemer
JSONSchemer.schema(Pathname.new(File.expand_path("../stable/verbs.json", __dir__)))
end
|
.wisp_schemer ⇒ Object
44
45
46
|
# File 'lib/wisp-schema.rb', line 44
def wisp_schemer
JSONSchemer.schema(Pathname.new(Wisp::SCHEMA_PATH))
end
|