pact-ffi 0.4.22-x86_64-linux-musl
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE.txt +21 -0
- data/README.md +118 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/ffi/linux-x64-musl/libpact_ffi.so +0 -0
- data/lib/pact/detect_os.rb +80 -0
- data/lib/pact/ffi/async_message_pact.rb +29 -0
- data/lib/pact/ffi/http_consumer.rb +40 -0
- data/lib/pact/ffi/logger.rb +34 -0
- data/lib/pact/ffi/message_consumer.rb +129 -0
- data/lib/pact/ffi/mock_server.rb +84 -0
- data/lib/pact/ffi/plugin_consumer.rb +40 -0
- data/lib/pact/ffi/sync_http_consumer.rb +36 -0
- data/lib/pact/ffi/sync_message_consumer.rb +38 -0
- data/lib/pact/ffi/utils.rb +150 -0
- data/lib/pact/ffi/verifier.rb +62 -0
- data/lib/pact/ffi/version.rb +5 -0
- data/lib/pact/ffi.rb +386 -0
- metadata +161 -0
data/lib/pact/ffi.rb
ADDED
@@ -0,0 +1,386 @@
|
|
1
|
+
# require 'pact-ffi/version'
|
2
|
+
require 'ffi'
|
3
|
+
require 'pact/detect_os'
|
4
|
+
|
5
|
+
module PactFfi
|
6
|
+
extend FFI::Library
|
7
|
+
ffi_lib DetectOS.get_bin_path
|
8
|
+
|
9
|
+
# at least neccessary on x64-mingw-ucrt as uint32_type is undefined
|
10
|
+
# also neccessary on linux aarch64 it seems
|
11
|
+
# DetectOS.windows? || DetectOS.linux_arm? ? (typedef :uint32, :uint32_type) : (typedef :uint32_t, :uint32_type) (typedef :uint32, :uint32_type)
|
12
|
+
(typedef :uint32, :uint32_type)
|
13
|
+
FfiSpecificationVersion = Hash[
|
14
|
+
'SPECIFICATION_VERSION_UNKNOWN' => 0,
|
15
|
+
'SPECIFICATION_VERSION_V1' => 1,
|
16
|
+
'SPECIFICATION_VERSION_V1_1' => 2,
|
17
|
+
'SPECIFICATION_VERSION_V2' => 3,
|
18
|
+
'SPECIFICATION_VERSION_V3' => 4,
|
19
|
+
'SPECIFICATION_VERSION_V4' => 5,
|
20
|
+
]
|
21
|
+
FfiWritePactResponse = Hash[
|
22
|
+
'SUCCESS' => 0,
|
23
|
+
'GENERAL_PANIC' => 1,
|
24
|
+
'UNABLE_TO_WRITE_PACT_FILE' => 2,
|
25
|
+
'MOCK_SERVER_NOT_FOUND' => 3,
|
26
|
+
]
|
27
|
+
FfiWriteMessagePactResponse = Hash[
|
28
|
+
'SUCCESS' => 0,
|
29
|
+
'UNABLE_TO_WRITE_PACT_FILE' => 1,
|
30
|
+
'MESSAGE_HANDLE_INVALID' => 2,
|
31
|
+
'MOCK_SERVER_NOT_FOUND' => 3,
|
32
|
+
]
|
33
|
+
FfiConfigurePluginResponse = Hash[
|
34
|
+
'SUCCESS' => 0,
|
35
|
+
'GENERAL_PANIC' => 1,
|
36
|
+
'FAILED_TO_LOAD_PLUGIN' => 2,
|
37
|
+
'PACT_HANDLE_INVALID' => 3,
|
38
|
+
]
|
39
|
+
FfiPluginInteractionResponse = Hash[
|
40
|
+
'SUCCESS' => 0,
|
41
|
+
'A_GENERAL_PANIC_WAS_CAUGHT' => 1,
|
42
|
+
'MOCK_SERVER_HAS_ALREADY_BEEN_STARTED' => 2,
|
43
|
+
'INTERACTION_HANDLE_IS_INVALID' => 3,
|
44
|
+
'CONTENT_TYPE_IS_NOT_VALID' => 4,
|
45
|
+
'CONTENTS_JSON_IS_NOT_VALID_JSON' => 5,
|
46
|
+
'PLUGIN_RETURNED_AN_ERROR' => 6,
|
47
|
+
]
|
48
|
+
FfiInteractionPart = Hash[
|
49
|
+
'INTERACTION_PART_REQUEST' => 0,
|
50
|
+
'INTERACTION_PART_RESPONSE' => 1,
|
51
|
+
]
|
52
|
+
# /*
|
53
|
+
# -1 A null pointer was received
|
54
|
+
# -2 The pact JSON could not be parsed
|
55
|
+
# -3 The mock server could not be started
|
56
|
+
# -4 The method panicked
|
57
|
+
# -5 The address is not valid
|
58
|
+
# -6 Could not create the TLS configuration with the self-signed certificate
|
59
|
+
# */
|
60
|
+
FfiPluginCreateMockServerErrors = Hash[
|
61
|
+
'NULL_POINTER' => -1,
|
62
|
+
'JSON_PARSE_ERROR' => -2,
|
63
|
+
'MOCK_SERVER_START_FAIL' => -3,
|
64
|
+
'CORE_PANIC' => -4,
|
65
|
+
'ADDRESS_NOT_VALID' => -5,
|
66
|
+
'TLS_CONFIG' => -6,
|
67
|
+
]
|
68
|
+
# /*
|
69
|
+
# * | Error | Description |
|
70
|
+
# * |-------|-------------|
|
71
|
+
# * | 1 | The verification process failed, see output for errors |
|
72
|
+
# * | 2 | A null pointer was received |
|
73
|
+
# * | 3 | The method panicked |
|
74
|
+
# * | 4 | Invalid arguments were provided to the verification process |
|
75
|
+
# */
|
76
|
+
FfiVerifyProviderResponse = Hash[
|
77
|
+
'VERIFICATION_SUCCESSFUL' => 0,
|
78
|
+
'VERIFICATION_FAILED' => 1,
|
79
|
+
'NULL_POINTER_RECEIVED' => 2,
|
80
|
+
'METHOD_PANICKED' => 3,
|
81
|
+
'INVALID_ARGUMENTS' => 4,
|
82
|
+
]
|
83
|
+
|
84
|
+
FfiPluginFunctionResult = Hash[
|
85
|
+
'RESULT_OK' => 0,
|
86
|
+
'RESULT_FAILED' => 1,
|
87
|
+
]
|
88
|
+
|
89
|
+
FfiLogLevelFilter = Hash[
|
90
|
+
'LOG_LEVEL_OFF' => 0,
|
91
|
+
'LOG_LEVEL_ERROR' => 1,
|
92
|
+
'LOG_LEVEL_WARN' => 2,
|
93
|
+
'LOG_LEVEL_INFO' => 3,
|
94
|
+
'LOG_LEVEL_DEBUG' => 4,
|
95
|
+
'LOG_LEVEL_TRACE' => 5
|
96
|
+
]
|
97
|
+
FfiLogLevel = Hash[
|
98
|
+
'LOG_LEVEL_OFF' => 'OFF',
|
99
|
+
'LOG_LEVEL_ERROR' => 'ERROR',
|
100
|
+
'LOG_LEVEL_WARN' => 'WARN',
|
101
|
+
'LOG_LEVEL_INFO' => 'INFO',
|
102
|
+
'LOG_LEVEL_DEBUG' => 'DEBUG',
|
103
|
+
'LOG_LEVEL_TRACE' => 'TRACE'
|
104
|
+
]
|
105
|
+
|
106
|
+
# These bork on windows not sure they they are added in
|
107
|
+
# as part of deno-bindgen, maybe the include headers
|
108
|
+
# attach_function :malloc, %i[size_t], :pointer
|
109
|
+
# attach_function :calloc, %i[size_t size_t], :pointer
|
110
|
+
# attach_function :realloc, %i[pointer size_t], :pointer
|
111
|
+
# attach_function :free, %i[pointer], :void
|
112
|
+
# attach_function :posix_memalign, %i[pointer size_t size_t], :int32
|
113
|
+
# attach_function :abort, %i[], :void
|
114
|
+
# attach_function :getenv, %i[string], :string
|
115
|
+
# attach_function :realpath, %i[string string], :string
|
116
|
+
|
117
|
+
attach_function :version, :pactffi_version, %i[], :string
|
118
|
+
attach_function :init, :pactffi_init, %i[string], :void
|
119
|
+
attach_function :init_with_log_level, :pactffi_init_with_log_level, %i[string], :void
|
120
|
+
attach_function :enable_ansi_support, :pactffi_enable_ansi_support, %i[], :void
|
121
|
+
attach_function :log_message, :pactffi_log_message, %i[string string string], :void
|
122
|
+
attach_function :match_message, :pactffi_match_message, %i[pointer pointer], :pointer
|
123
|
+
attach_function :mismatches_get_iter, :pactffi_mismatches_get_iter, %i[pointer], :pointer
|
124
|
+
attach_function :mismatches_delete, :pactffi_mismatches_delete, %i[pointer], :void
|
125
|
+
attach_function :mismatches_iter_next, :pactffi_mismatches_iter_next, %i[pointer], :pointer
|
126
|
+
attach_function :mismatches_iter_delete, :pactffi_mismatches_iter_delete, %i[pointer], :void
|
127
|
+
attach_function :mismatch_to_json, :pactffi_mismatch_to_json, %i[pointer], :string
|
128
|
+
attach_function :mismatch_type, :pactffi_mismatch_type, %i[pointer], :string
|
129
|
+
attach_function :mismatch_summary, :pactffi_mismatch_summary, %i[pointer], :string
|
130
|
+
attach_function :mismatch_description, :pactffi_mismatch_description, %i[pointer], :string
|
131
|
+
attach_function :mismatch_ansi_description, :pactffi_mismatch_ansi_description, %i[pointer], :string
|
132
|
+
attach_function :get_error_message, :pactffi_get_error_message, %i[string int32], :int32
|
133
|
+
attach_function :log_to_stdout, :pactffi_log_to_stdout, %i[int32], :int32
|
134
|
+
attach_function :log_to_stderr, :pactffi_log_to_stderr, %i[int32], :int32
|
135
|
+
attach_function :log_to_file, :pactffi_log_to_file, %i[string int32], :int32
|
136
|
+
attach_function :log_to_buffer, :pactffi_log_to_buffer, %i[int32], :int32
|
137
|
+
attach_function :logger_init, :pactffi_logger_init, %i[], :void
|
138
|
+
attach_function :logger_attach_sink, :pactffi_logger_attach_sink, %i[string int32], :int32
|
139
|
+
attach_function :logger_apply, :pactffi_logger_apply, %i[], :int32
|
140
|
+
attach_function :fetch_log_buffer, :pactffi_fetch_log_buffer, %i[string], :string
|
141
|
+
attach_function :parse_pact_json, :pactffi_parse_pact_json, %i[string], :pointer
|
142
|
+
attach_function :pact_model_delete, :pactffi_pact_model_delete, %i[pointer], :void
|
143
|
+
attach_function :pact_model_interaction_iterator, :pactffi_pact_model_interaction_iterator, %i[pointer], :pointer
|
144
|
+
attach_function :pact_spec_version, :pactffi_pact_spec_version, %i[pointer], :int32
|
145
|
+
attach_function :pact_interaction_delete, :pactffi_pact_interaction_delete, %i[pointer], :void
|
146
|
+
attach_function :async_message_new, :pactffi_async_message_new, %i[], :pointer
|
147
|
+
attach_function :async_message_delete, :pactffi_async_message_delete, %i[pointer], :void
|
148
|
+
attach_function :async_message_get_contents, :pactffi_async_message_get_contents, %i[pointer], :pointer
|
149
|
+
attach_function :async_message_get_contents_str, :pactffi_async_message_get_contents_str, %i[pointer], :string
|
150
|
+
attach_function :async_message_set_contents_str, :pactffi_async_message_set_contents_str, %i[pointer string string], :void
|
151
|
+
attach_function :async_message_get_contents_length, :pactffi_async_message_get_contents_length, %i[pointer], :size_t
|
152
|
+
attach_function :async_message_get_contents_bin, :pactffi_async_message_get_contents_bin, %i[pointer], :pointer
|
153
|
+
attach_function :async_message_set_contents_bin, :pactffi_async_message_set_contents_bin, %i[pointer pointer size_t string], :void
|
154
|
+
attach_function :async_message_get_description, :pactffi_async_message_get_description, %i[pointer], :string
|
155
|
+
attach_function :async_message_set_description, :pactffi_async_message_set_description, %i[pointer string], :int32
|
156
|
+
attach_function :async_message_get_provider_state, :pactffi_async_message_get_provider_state, %i[pointer uint32_type], :pointer
|
157
|
+
attach_function :async_message_get_provider_state_iter, :pactffi_async_message_get_provider_state_iter, %i[pointer], :pointer
|
158
|
+
attach_function :consumer_get_name, :pactffi_consumer_get_name, %i[pointer], :string
|
159
|
+
attach_function :pact_get_consumer, :pactffi_pact_get_consumer, %i[pointer], :pointer
|
160
|
+
attach_function :pact_consumer_delete, :pactffi_pact_consumer_delete, %i[pointer], :void
|
161
|
+
attach_function :message_contents_get_contents_str, :pactffi_message_contents_get_contents_str, %i[pointer], :string
|
162
|
+
attach_function :message_contents_set_contents_str, :pactffi_message_contents_set_contents_str, %i[pointer string string], :void
|
163
|
+
attach_function :message_contents_get_contents_length, :pactffi_message_contents_get_contents_length, %i[pointer], :size_t
|
164
|
+
attach_function :message_contents_get_contents_bin, :pactffi_message_contents_get_contents_bin, %i[pointer], :pointer
|
165
|
+
attach_function :message_contents_set_contents_bin, :pactffi_message_contents_set_contents_bin, %i[pointer pointer size_t string], :void
|
166
|
+
attach_function :message_contents_get_metadata_iter, :pactffi_message_contents_get_metadata_iter, %i[pointer], :pointer
|
167
|
+
attach_function :message_contents_get_matching_rule_iter, :pactffi_message_contents_get_matching_rule_iter, %i[pointer int32], :pointer
|
168
|
+
attach_function :request_contents_get_matching_rule_iter, :pactffi_request_contents_get_matching_rule_iter, %i[pointer int32], :pointer
|
169
|
+
attach_function :response_contents_get_matching_rule_iter, :pactffi_response_contents_get_matching_rule_iter, %i[pointer int32], :pointer
|
170
|
+
attach_function :message_contents_get_generators_iter, :pactffi_message_contents_get_generators_iter, %i[pointer int32], :pointer
|
171
|
+
attach_function :request_contents_get_generators_iter, :pactffi_request_contents_get_generators_iter, %i[pointer int32], :pointer
|
172
|
+
attach_function :response_contents_get_generators_iter, :pactffi_response_contents_get_generators_iter, %i[pointer int32], :pointer
|
173
|
+
attach_function :parse_matcher_definition, :pactffi_parse_matcher_definition, %i[string], :pointer
|
174
|
+
attach_function :matcher_definition_error, :pactffi_matcher_definition_error, %i[pointer], :string
|
175
|
+
attach_function :matcher_definition_value, :pactffi_matcher_definition_value, %i[pointer], :string
|
176
|
+
attach_function :matcher_definition_delete, :pactffi_matcher_definition_delete, %i[pointer], :void
|
177
|
+
attach_function :matcher_definition_generator, :pactffi_matcher_definition_generator, %i[pointer], :pointer
|
178
|
+
attach_function :matcher_definition_value_type, :pactffi_matcher_definition_value_type, %i[pointer], :int32
|
179
|
+
attach_function :matching_rule_iter_delete, :pactffi_matching_rule_iter_delete, %i[pointer], :void
|
180
|
+
attach_function :matcher_definition_iter, :pactffi_matcher_definition_iter, %i[pointer], :pointer
|
181
|
+
attach_function :matching_rule_iter_next, :pactffi_matching_rule_iter_next, %i[pointer], :pointer
|
182
|
+
attach_function :matching_rule_id, :pactffi_matching_rule_id, %i[pointer], :uint16
|
183
|
+
attach_function :matching_rule_value, :pactffi_matching_rule_value, %i[pointer], :string
|
184
|
+
attach_function :matching_rule_pointer, :pactffi_matching_rule_pointer, %i[pointer], :pointer
|
185
|
+
attach_function :matching_rule_reference_name, :pactffi_matching_rule_reference_name, %i[pointer], :string
|
186
|
+
attach_function :validate_datetime, :pactffi_validate_datetime, %i[string string], :int32
|
187
|
+
attach_function :generator_to_json, :pactffi_generator_to_json, %i[pointer], :string
|
188
|
+
attach_function :generator_generate_string, :pactffi_generator_generate_string, %i[pointer string], :string
|
189
|
+
attach_function :generator_generate_integer, :pactffi_generator_generate_integer, %i[pointer string], :uint16
|
190
|
+
attach_function :generators_iter_delete, :pactffi_generators_iter_delete, %i[pointer], :void
|
191
|
+
attach_function :generators_iter_next, :pactffi_generators_iter_next, %i[pointer], :pointer
|
192
|
+
attach_function :generators_iter_pair_delete, :pactffi_generators_iter_pair_delete, %i[pointer], :void
|
193
|
+
attach_function :sync_http_new, :pactffi_sync_http_new, %i[], :pointer
|
194
|
+
attach_function :sync_http_delete, :pactffi_sync_http_delete, %i[pointer], :void
|
195
|
+
attach_function :sync_http_get_request, :pactffi_sync_http_get_request, %i[pointer], :pointer
|
196
|
+
attach_function :sync_http_get_request_contents, :pactffi_sync_http_get_request_contents, %i[pointer], :string
|
197
|
+
attach_function :sync_http_set_request_contents, :pactffi_sync_http_set_request_contents, %i[pointer string string], :void
|
198
|
+
attach_function :sync_http_get_request_contents_length, :pactffi_sync_http_get_request_contents_length, %i[pointer], :size_t
|
199
|
+
attach_function :sync_http_get_request_contents_bin, :pactffi_sync_http_get_request_contents_bin, %i[pointer], :pointer
|
200
|
+
attach_function :sync_http_set_request_contents_bin, :pactffi_sync_http_set_request_contents_bin, %i[pointer pointer size_t string], :void
|
201
|
+
attach_function :sync_http_get_response, :pactffi_sync_http_get_response, %i[pointer], :pointer
|
202
|
+
attach_function :sync_http_get_response_contents, :pactffi_sync_http_get_response_contents, %i[pointer], :string
|
203
|
+
attach_function :sync_http_set_response_contents, :pactffi_sync_http_set_response_contents, %i[pointer string string], :void
|
204
|
+
attach_function :sync_http_get_response_contents_length, :pactffi_sync_http_get_response_contents_length, %i[pointer], :size_t
|
205
|
+
attach_function :sync_http_get_response_contents_bin, :pactffi_sync_http_get_response_contents_bin, %i[pointer], :pointer
|
206
|
+
attach_function :sync_http_set_response_contents_bin, :pactffi_sync_http_set_response_contents_bin, %i[pointer pointer size_t string], :void
|
207
|
+
attach_function :sync_http_get_description, :pactffi_sync_http_get_description, %i[pointer], :string
|
208
|
+
attach_function :sync_http_set_description, :pactffi_sync_http_set_description, %i[pointer string], :int32
|
209
|
+
attach_function :sync_http_get_provider_state, :pactffi_sync_http_get_provider_state, %i[pointer uint32_type], :pointer
|
210
|
+
attach_function :sync_http_get_provider_state_iter, :pactffi_sync_http_get_provider_state_iter, %i[pointer], :pointer
|
211
|
+
attach_function :pact_interaction_as_synchronous_http, :pactffi_pact_interaction_as_synchronous_http, %i[pointer], :pointer
|
212
|
+
attach_function :pact_interaction_as_message, :pactffi_pact_interaction_as_message, %i[pointer], :pointer
|
213
|
+
attach_function :pact_interaction_as_asynchronous_message, :pactffi_pact_interaction_as_asynchronous_message, %i[pointer], :pointer
|
214
|
+
attach_function :pact_interaction_as_synchronous_message, :pactffi_pact_interaction_as_synchronous_message, %i[pointer], :pointer
|
215
|
+
attach_function :pact_message_iter_delete, :pactffi_pact_message_iter_delete, %i[pointer], :void
|
216
|
+
attach_function :pact_message_iter_next, :pactffi_pact_message_iter_next, %i[pointer], :pointer
|
217
|
+
attach_function :pact_sync_message_iter_next, :pactffi_pact_sync_message_iter_next, %i[pointer], :pointer
|
218
|
+
attach_function :pact_sync_message_iter_delete, :pactffi_pact_sync_message_iter_delete, %i[pointer], :void
|
219
|
+
attach_function :pact_sync_http_iter_next, :pactffi_pact_sync_http_iter_next, %i[pointer], :pointer
|
220
|
+
attach_function :pact_sync_http_iter_delete, :pactffi_pact_sync_http_iter_delete, %i[pointer], :void
|
221
|
+
attach_function :pact_interaction_iter_next, :pactffi_pact_interaction_iter_next, %i[pointer], :pointer
|
222
|
+
attach_function :pact_interaction_iter_delete, :pactffi_pact_interaction_iter_delete, %i[pointer], :void
|
223
|
+
attach_function :matching_rule_to_json, :pactffi_matching_rule_to_json, %i[pointer], :string
|
224
|
+
attach_function :matching_rules_iter_delete, :pactffi_matching_rules_iter_delete, %i[pointer], :void
|
225
|
+
attach_function :matching_rules_iter_next, :pactffi_matching_rules_iter_next, %i[pointer], :pointer
|
226
|
+
attach_function :matching_rules_iter_pair_delete, :pactffi_matching_rules_iter_pair_delete, %i[pointer], :void
|
227
|
+
attach_function :message_new, :pactffi_message_new, %i[], :pointer
|
228
|
+
attach_function :message_new_from_json, :pactffi_message_new_from_json, %i[uint32_type string int32], :pointer
|
229
|
+
attach_function :message_new_from_body, :pactffi_message_new_from_body, %i[string string], :pointer
|
230
|
+
attach_function :message_delete, :pactffi_message_delete, %i[pointer], :void
|
231
|
+
attach_function :message_get_contents, :pactffi_message_get_contents, %i[pointer], :string
|
232
|
+
attach_function :message_set_contents, :pactffi_message_set_contents, %i[pointer string string], :void
|
233
|
+
attach_function :message_get_contents_length, :pactffi_message_get_contents_length, %i[pointer], :size_t
|
234
|
+
attach_function :message_get_contents_bin, :pactffi_message_get_contents_bin, %i[pointer], :pointer
|
235
|
+
attach_function :message_set_contents_bin, :pactffi_message_set_contents_bin, %i[pointer pointer size_t string], :void
|
236
|
+
attach_function :message_get_description, :pactffi_message_get_description, %i[pointer], :string
|
237
|
+
attach_function :message_set_description, :pactffi_message_set_description, %i[pointer string], :int32
|
238
|
+
attach_function :message_get_provider_state, :pactffi_message_get_provider_state, %i[pointer uint32_type], :pointer
|
239
|
+
attach_function :message_get_provider_state_iter, :pactffi_message_get_provider_state_iter, %i[pointer], :pointer
|
240
|
+
attach_function :provider_state_iter_next, :pactffi_provider_state_iter_next, %i[pointer], :pointer
|
241
|
+
attach_function :provider_state_iter_delete, :pactffi_provider_state_iter_delete, %i[pointer], :void
|
242
|
+
attach_function :message_find_metadata, :pactffi_message_find_metadata, %i[pointer string], :string
|
243
|
+
attach_function :message_insert_metadata, :pactffi_message_insert_metadata, %i[pointer string string], :int32
|
244
|
+
attach_function :message_metadata_iter_next, :pactffi_message_metadata_iter_next, %i[pointer], :pointer
|
245
|
+
attach_function :message_get_metadata_iter, :pactffi_message_get_metadata_iter, %i[pointer], :pointer
|
246
|
+
attach_function :message_metadata_iter_delete, :pactffi_message_metadata_iter_delete, %i[pointer], :void
|
247
|
+
attach_function :message_metadata_pair_delete, :pactffi_message_metadata_pair_delete, %i[pointer], :void
|
248
|
+
attach_function :message_pact_new_from_json, :pactffi_message_pact_new_from_json, %i[string string], :pointer
|
249
|
+
attach_function :message_pact_delete, :pactffi_message_pact_delete, %i[pointer], :void
|
250
|
+
attach_function :message_pact_get_consumer, :pactffi_message_pact_get_consumer, %i[pointer], :pointer
|
251
|
+
attach_function :message_pact_get_provider, :pactffi_message_pact_get_provider, %i[pointer], :pointer
|
252
|
+
attach_function :message_pact_get_message_iter, :pactffi_message_pact_get_message_iter, %i[pointer], :pointer
|
253
|
+
attach_function :message_pact_message_iter_next, :pactffi_message_pact_message_iter_next, %i[pointer], :pointer
|
254
|
+
attach_function :message_pact_message_iter_delete, :pactffi_message_pact_message_iter_delete, %i[pointer], :void
|
255
|
+
attach_function :message_pact_find_metadata, :pactffi_message_pact_find_metadata, %i[pointer string string], :string
|
256
|
+
attach_function :message_pact_get_metadata_iter, :pactffi_message_pact_get_metadata_iter, %i[pointer], :pointer
|
257
|
+
attach_function :message_pact_metadata_iter_next, :pactffi_message_pact_metadata_iter_next, %i[pointer], :pointer
|
258
|
+
attach_function :message_pact_metadata_iter_delete, :pactffi_message_pact_metadata_iter_delete, %i[pointer], :void
|
259
|
+
attach_function :message_pact_metadata_triple_delete, :pactffi_message_pact_metadata_triple_delete, %i[pointer], :void
|
260
|
+
attach_function :provider_get_name, :pactffi_provider_get_name, %i[pointer], :string
|
261
|
+
attach_function :pact_get_provider, :pactffi_pact_get_provider, %i[pointer], :pointer
|
262
|
+
attach_function :pact_provider_delete, :pactffi_pact_provider_delete, %i[pointer], :void
|
263
|
+
attach_function :provider_state_get_name, :pactffi_provider_state_get_name, %i[pointer], :string
|
264
|
+
attach_function :provider_state_get_param_iter, :pactffi_provider_state_get_param_iter, %i[pointer], :pointer
|
265
|
+
attach_function :provider_state_param_iter_next, :pactffi_provider_state_param_iter_next, %i[pointer], :pointer
|
266
|
+
attach_function :provider_state_delete, :pactffi_provider_state_delete, %i[pointer], :void
|
267
|
+
attach_function :provider_state_param_iter_delete, :pactffi_provider_state_param_iter_delete, %i[pointer], :void
|
268
|
+
attach_function :provider_state_param_pair_delete, :pactffi_provider_state_param_pair_delete, %i[pointer], :void
|
269
|
+
attach_function :sync_message_new, :pactffi_sync_message_new, %i[], :pointer
|
270
|
+
attach_function :sync_message_delete, :pactffi_sync_message_delete, %i[pointer], :void
|
271
|
+
attach_function :sync_message_get_request_contents_str, :pactffi_sync_message_get_request_contents_str, %i[pointer], :string
|
272
|
+
attach_function :sync_message_set_request_contents_str, :pactffi_sync_message_set_request_contents_str, %i[pointer string string], :void
|
273
|
+
attach_function :sync_message_get_request_contents_length, :pactffi_sync_message_get_request_contents_length, %i[pointer], :size_t
|
274
|
+
attach_function :sync_message_get_request_contents_bin, :pactffi_sync_message_get_request_contents_bin, %i[pointer], :pointer
|
275
|
+
attach_function :sync_message_set_request_contents_bin, :pactffi_sync_message_set_request_contents_bin, %i[pointer pointer size_t string], :void
|
276
|
+
attach_function :sync_message_get_request_contents, :pactffi_sync_message_get_request_contents, %i[pointer], :pointer
|
277
|
+
attach_function :sync_message_get_number_responses, :pactffi_sync_message_get_number_responses, %i[pointer], :size_t
|
278
|
+
attach_function :sync_message_get_response_contents_str, :pactffi_sync_message_get_response_contents_str, %i[pointer size_t], :string
|
279
|
+
attach_function :sync_message_set_response_contents_str, :pactffi_sync_message_set_response_contents_str, %i[pointer size_t string string], :void
|
280
|
+
attach_function :sync_message_get_response_contents_length, :pactffi_sync_message_get_response_contents_length, %i[pointer size_t], :size_t
|
281
|
+
attach_function :sync_message_get_response_contents_bin, :pactffi_sync_message_get_response_contents_bin, %i[pointer size_t], :pointer
|
282
|
+
attach_function :sync_message_set_response_contents_bin, :pactffi_sync_message_set_response_contents_bin, %i[pointer size_t pointer size_t string], :void
|
283
|
+
attach_function :sync_message_get_response_contents, :pactffi_sync_message_get_response_contents, %i[pointer size_t], :pointer
|
284
|
+
attach_function :sync_message_get_description, :pactffi_sync_message_get_description, %i[pointer], :string
|
285
|
+
attach_function :sync_message_set_description, :pactffi_sync_message_set_description, %i[pointer string], :int32
|
286
|
+
attach_function :sync_message_get_provider_state, :pactffi_sync_message_get_provider_state, %i[pointer uint32_type], :pointer
|
287
|
+
attach_function :sync_message_get_provider_state_iter, :pactffi_sync_message_get_provider_state_iter, %i[pointer], :pointer
|
288
|
+
attach_function :string_delete, :pactffi_string_delete, %i[string], :void
|
289
|
+
attach_function :create_mock_server, :pactffi_create_mock_server, %i[string string bool], :int32
|
290
|
+
attach_function :get_tls_ca_certificate, :pactffi_get_tls_ca_certificate, %i[], :string
|
291
|
+
attach_function :create_mock_server_for_pact, :pactffi_create_mock_server_for_pact, %i[uint16 string bool], :int32
|
292
|
+
attach_function :create_mock_server_for_transport, :pactffi_create_mock_server_for_transport, %i[uint16 string uint16 string string], :int32
|
293
|
+
attach_function :mock_server_matched, :pactffi_mock_server_matched, %i[int32], :bool
|
294
|
+
attach_function :mock_server_mismatches, :pactffi_mock_server_mismatches, %i[int32], :string
|
295
|
+
attach_function :cleanup_mock_server, :pactffi_cleanup_mock_server, %i[int32], :bool
|
296
|
+
attach_function :write_pact_file, :pactffi_write_pact_file, %i[int32 string bool], :int32
|
297
|
+
attach_function :mock_server_logs, :pactffi_mock_server_logs, %i[int32], :string
|
298
|
+
attach_function :generate_datetime_string, :pactffi_generate_datetime_string, %i[string], :pointer
|
299
|
+
attach_function :check_regex, :pactffi_check_regex, %i[string string], :bool
|
300
|
+
attach_function :generate_regex_value, :pactffi_generate_regex_value, %i[string], :pointer
|
301
|
+
attach_function :free_string, :pactffi_free_string, %i[string], :void
|
302
|
+
attach_function :new_pact, :pactffi_new_pact, %i[string string], :uint16
|
303
|
+
attach_function :new_interaction, :pactffi_new_interaction, %i[uint16 string], :uint32_type
|
304
|
+
attach_function :new_message_interaction, :pactffi_new_message_interaction, %i[uint16 string], :uint32_type
|
305
|
+
attach_function :new_sync_message_interaction, :pactffi_new_sync_message_interaction, %i[uint16 string], :uint32_type
|
306
|
+
attach_function :upon_receiving, :pactffi_upon_receiving, %i[uint32_type string], :bool
|
307
|
+
attach_function :given, :pactffi_given, %i[uint32_type string], :bool
|
308
|
+
attach_function :given, :pactffi_given, %i[uint32_type string], :bool
|
309
|
+
attach_function :given_with_params, :pactffi_given_with_params, %i[uint32_type string string], :int32
|
310
|
+
attach_function :interaction_test_name, :pactffi_interaction_test_name, %i[uint32_type string], :uint32_type
|
311
|
+
attach_function :given_with_param, :pactffi_given_with_param, %i[uint32_type string string string], :bool
|
312
|
+
attach_function :with_request, :pactffi_with_request, %i[uint32_type string string], :bool
|
313
|
+
attach_function :with_query_parameter, :pactffi_with_query_parameter, %i[uint32_type string size_t string], :bool
|
314
|
+
attach_function :with_query_parameter_v2, :pactffi_with_query_parameter_v2, %i[uint32_type string size_t string], :bool
|
315
|
+
attach_function :with_specification, :pactffi_with_specification, %i[uint16 int32], :bool
|
316
|
+
attach_function :with_pact_metadata, :pactffi_with_pact_metadata, %i[uint16 string string string], :bool
|
317
|
+
attach_function :with_header, :pactffi_with_header, %i[uint32_type int32 string size_t string], :bool
|
318
|
+
attach_function :with_header_v2, :pactffi_with_header_v2, %i[uint32_type int32 string size_t string], :bool
|
319
|
+
attach_function :response_status, :pactffi_response_status, %i[uint32_type uint16], :bool
|
320
|
+
attach_function :with_body, :pactffi_with_body, %i[uint32_type int32 string string], :bool
|
321
|
+
attach_function :with_binary_file, :pactffi_with_binary_file, %i[uint32_type int32 string pointer size_t], :bool
|
322
|
+
attach_function :with_multipart_file, :pactffi_with_multipart_file, %i[uint32_type int32 string string string], :pointer
|
323
|
+
attach_function :pact_handle_get_message_iter, :pactffi_pact_handle_get_message_iter, %i[uint16], :pointer
|
324
|
+
attach_function :pact_handle_get_sync_message_iter, :pactffi_pact_handle_get_sync_message_iter, %i[uint16], :pointer
|
325
|
+
attach_function :pact_handle_get_sync_http_iter, :pactffi_pact_handle_get_sync_http_iter, %i[uint16], :pointer
|
326
|
+
attach_function :new_message_pact, :pactffi_new_message_pact, %i[string string], :uint16
|
327
|
+
attach_function :new_message, :pactffi_new_message, %i[uint16 string], :uint32_type
|
328
|
+
attach_function :message_expects_to_receive, :pactffi_message_expects_to_receive, %i[uint32_type string], :void
|
329
|
+
attach_function :message_given, :pactffi_message_given, %i[uint32_type string], :void
|
330
|
+
attach_function :message_given_with_param, :pactffi_message_given_with_param, %i[uint32_type string string string], :void
|
331
|
+
attach_function :message_with_contents, :pactffi_message_with_contents, %i[uint32_type string pointer size_t], :void
|
332
|
+
attach_function :message_with_metadata, :pactffi_message_with_metadata, %i[uint32_type string string], :void
|
333
|
+
attach_function :message_with_metadata_v2, :pactffi_message_with_metadata_v2, %i[uint32_type string string], :void
|
334
|
+
attach_function :with_metadata, :pactffi_with_metadata, %i[uint32_type string string int], :void
|
335
|
+
attach_function :message_reify, :pactffi_message_reify, %i[uint32_type], :string
|
336
|
+
attach_function :write_message_pact_file, :pactffi_write_message_pact_file, %i[uint16 string bool], :int32
|
337
|
+
attach_function :with_message_pact_metadata, :pactffi_with_message_pact_metadata, %i[uint16 string string string], :void
|
338
|
+
attach_function :pact_handle_write_file, :pactffi_pact_handle_write_file, %i[uint16 string bool], :int32
|
339
|
+
attach_function :new_async_message, :pactffi_new_async_message, %i[uint16 string], :uint32_type
|
340
|
+
attach_function :free_pact_handle, :pactffi_free_pact_handle, %i[uint16], :uint32_type
|
341
|
+
attach_function :free_message_pact_handle, :pactffi_free_message_pact_handle, %i[uint16], :uint32_type
|
342
|
+
attach_function :verify, :pactffi_verify, %i[string], :int32
|
343
|
+
attach_function :verifier_new, :pactffi_verifier_new, %i[], :pointer
|
344
|
+
attach_function :verifier_new_for_application, :pactffi_verifier_new_for_application, %i[string string], :pointer
|
345
|
+
attach_function :verifier_shutdown, :pactffi_verifier_shutdown, %i[pointer], :void
|
346
|
+
attach_function :verifier_set_provider_info, :pactffi_verifier_set_provider_info, %i[pointer string string string uint16 string], :void
|
347
|
+
attach_function :verifier_add_provider_transport, :pactffi_verifier_add_provider_transport, %i[pointer string uint16 string string], :void
|
348
|
+
attach_function :verifier_set_filter_info, :pactffi_verifier_set_filter_info, %i[pointer string string uint8], :void
|
349
|
+
attach_function :verifier_set_provider_state, :pactffi_verifier_set_provider_state, %i[pointer string uint8 uint8], :void
|
350
|
+
attach_function :verifier_set_verification_options, :pactffi_verifier_set_verification_options, %i[pointer uint8 ulong_long], :int32
|
351
|
+
attach_function :verifier_set_coloured_output, :pactffi_verifier_set_coloured_output, %i[pointer uint8], :int32
|
352
|
+
attach_function :verifier_set_no_pacts_is_error, :pactffi_verifier_set_no_pacts_is_error, %i[pointer uint8], :int32
|
353
|
+
attach_function :verifier_set_publish_options, :pactffi_verifier_set_publish_options, %i[pointer string string pointer uint16 string], :int32
|
354
|
+
attach_function :verifier_set_consumer_filters, :pactffi_verifier_set_consumer_filters, %i[pointer pointer uint16], :void
|
355
|
+
attach_function :verifier_add_custom_header, :pactffi_verifier_add_custom_header, %i[pointer string string], :void
|
356
|
+
attach_function :verifier_add_file_source, :pactffi_verifier_add_file_source, %i[pointer string], :void
|
357
|
+
attach_function :verifier_add_directory_source, :pactffi_verifier_add_directory_source, %i[pointer string], :void
|
358
|
+
attach_function :verifier_url_source, :pactffi_verifier_url_source, %i[pointer string string string string], :void
|
359
|
+
attach_function :verifier_broker_source, :pactffi_verifier_broker_source, %i[pointer string string string string], :void
|
360
|
+
attach_function :verifier_broker_source_with_selectors, :pactffi_verifier_broker_source_with_selectors, %i[pointer string string string string uint8 string pointer uint16 string pointer uint16 pointer uint16], :void
|
361
|
+
attach_function :verifier_execute, :pactffi_verifier_execute, %i[pointer], :int32
|
362
|
+
attach_function :verifier_cli_args, :pactffi_verifier_cli_args, %i[], :string
|
363
|
+
attach_function :verifier_logs, :pactffi_verifier_logs, %i[pointer], :string
|
364
|
+
attach_function :verifier_logs_for_provider, :pactffi_verifier_logs_for_provider, %i[string], :string
|
365
|
+
attach_function :verifier_output, :pactffi_verifier_output, %i[pointer uint8], :string
|
366
|
+
attach_function :verifier_json, :pactffi_verifier_json, %i[pointer], :string
|
367
|
+
attach_function :using_plugin, :pactffi_using_plugin, %i[uint16 string string], :uint32_type
|
368
|
+
attach_function :cleanup_plugins, :pactffi_cleanup_plugins, %i[uint16], :void
|
369
|
+
attach_function :interaction_contents, :pactffi_interaction_contents, %i[uint32_type int32 string string], :uint32_type
|
370
|
+
attach_function :matches_string_value, :pactffi_matches_string_value, %i[pointer string string uint8], :string
|
371
|
+
attach_function :matches_u64_value, :pactffi_matches_u64_value, %i[pointer ulong_long ulong_long uint8], :string
|
372
|
+
attach_function :matches_i64_value, :pactffi_matches_i64_value, %i[pointer int64 int64 uint8], :string
|
373
|
+
attach_function :matches_f64_value, :pactffi_matches_f64_value, %i[pointer double double uint8], :string
|
374
|
+
attach_function :matches_bool_value, :pactffi_matches_bool_value, %i[pointer uint8 uint8 uint8], :string
|
375
|
+
attach_function :matches_binary_value, :pactffi_matches_binary_value, %i[pointer pointer ulong_long pointer ulong_long uint8], :string
|
376
|
+
attach_function :matches_json_value, :pactffi_matches_json_value, %i[pointer string string uint8], :string
|
377
|
+
attach_function :pact_handle_to_pointer, :pactffi_pact_handle_to_pointer, %i[uint16], :pointer
|
378
|
+
attach_function :handle_get_pact_spec_version, :pactffi_handle_get_pact_spec_version, %i[uint16], :int32
|
379
|
+
attach_function :with_multipart_file, :pactffi_with_multipart_file, %i[uint32_type int32 string string string], :pointer
|
380
|
+
attach_function :set_header, :pactffi_set_header, %i[uint32_type int32 string string], :bool
|
381
|
+
attach_function :with_binary_body, :pactffi_with_binary_body, %i[uint32_type int32 string pointer size_t], :bool
|
382
|
+
attach_function :with_matching_rules, :pactffi_with_matching_rules, %i[uint32_type int32 string], :bool
|
383
|
+
attach_function :with_multipart_file_v2, :pactffi_with_multipart_file_v2, %i[uint32_type int32 string string string string], :pointer
|
384
|
+
attach_function :message_with_metadata_v2, :pactffi_message_with_metadata_v2, %i[uint32_type string string], :void
|
385
|
+
attach_function :with_generators, :pactffi_with_generators, %i[uint32_type int string], :bool
|
386
|
+
end
|
metadata
ADDED
@@ -0,0 +1,161 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: pact-ffi
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.4.22
|
5
|
+
platform: x86_64-linux-musl
|
6
|
+
authors:
|
7
|
+
- Yousaf Nabi
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2024-08-02 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: cucumber
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '9.2'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '9.2'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: httparty
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 0.21.0
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.21.0
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: nokogiri
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '1.16'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '1.16'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rake
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '10.0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '10.0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rspec
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '3.0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '3.0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: webrick
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '1.8'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '1.8'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: ffi
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '1.15'
|
104
|
+
type: :runtime
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - "~>"
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '1.15'
|
111
|
+
description: Enables consumer driven contract testing, providing a mock service and
|
112
|
+
DSL for the consumer project, and interaction playback and verification for the
|
113
|
+
service provider project.
|
114
|
+
email:
|
115
|
+
- you@saf.dev
|
116
|
+
executables: []
|
117
|
+
extensions: []
|
118
|
+
extra_rdoc_files: []
|
119
|
+
files:
|
120
|
+
- LICENSE.txt
|
121
|
+
- README.md
|
122
|
+
- bin/console
|
123
|
+
- bin/setup
|
124
|
+
- ffi/linux-x64-musl/libpact_ffi.so
|
125
|
+
- lib/pact/detect_os.rb
|
126
|
+
- lib/pact/ffi.rb
|
127
|
+
- lib/pact/ffi/async_message_pact.rb
|
128
|
+
- lib/pact/ffi/http_consumer.rb
|
129
|
+
- lib/pact/ffi/logger.rb
|
130
|
+
- lib/pact/ffi/message_consumer.rb
|
131
|
+
- lib/pact/ffi/mock_server.rb
|
132
|
+
- lib/pact/ffi/plugin_consumer.rb
|
133
|
+
- lib/pact/ffi/sync_http_consumer.rb
|
134
|
+
- lib/pact/ffi/sync_message_consumer.rb
|
135
|
+
- lib/pact/ffi/utils.rb
|
136
|
+
- lib/pact/ffi/verifier.rb
|
137
|
+
- lib/pact/ffi/version.rb
|
138
|
+
homepage: https://github.com/you54f/pact-ffi
|
139
|
+
licenses:
|
140
|
+
- MIT
|
141
|
+
metadata: {}
|
142
|
+
post_install_message:
|
143
|
+
rdoc_options: []
|
144
|
+
require_paths:
|
145
|
+
- lib
|
146
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
147
|
+
requirements:
|
148
|
+
- - ">="
|
149
|
+
- !ruby/object:Gem::Version
|
150
|
+
version: '0'
|
151
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
152
|
+
requirements:
|
153
|
+
- - ">="
|
154
|
+
- !ruby/object:Gem::Version
|
155
|
+
version: '0'
|
156
|
+
requirements: []
|
157
|
+
rubygems_version: 3.5.11
|
158
|
+
signing_key:
|
159
|
+
specification_version: 4
|
160
|
+
summary: Pact Reference FFI libpact_ffi library wrapper
|
161
|
+
test_files: []
|