123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197openCmdlinerletocaml_output=Arg.(value&opt(somestring)None&info["o";"output"]~doc:"Filename for the generated tests. Useful for generating multiple \
test files per module under test."~absent:"concatenation of INTERFACE without the file extension and \
\"_tests.ml\""~docv:"OCAML_OUTPUT")letinterface_file=Arg.(required&pos0(somestring)None&info[]~doc:"Interface file containing Gospel specifications."~docv:"INTERFACE")letpackage_name=Arg.(value&opt(somestring)None&info["p";"package"]~doc:"Package name."~docv:"PACKAGE")letwith_stdout_to=Arg.(value&opt(somestring)None&info["w";"with-stdout-to"]~doc:"Filename for the generated dune rules. For use on the command line."~docv:"DUNE_OUTPUT")letgen_alias=Arg.(value&opt(somestring)None&info["gen-alias"]~doc:"Alias to which the OCaml code generation will be attached."~docv:"GEN_ALIAS")letrun_alias=Arg.(value&opt(somestring)None&info["run-alias"]~doc:"Alias to which the execution of the generated OCaml code will be \
attached."~docv:"RUN_ALIAS")modulePlugin:sigvalcmd:unitCmd.tend=structmoduleQcheck_stm:sigvalcmd:unitCmd.tend=structletinfo=Cmd.info"qcheck-stm"~doc:"Generate Dune rules for the qcheck-stm plugin."letconfig_file=Arg.(value&opt(somestring)None&info["c";"config"]~doc:"Configuration file for Ortac/QCheck-STM. Useful for generating \
multiple test files per module under test."~absent:"concatenation of INTERFACE without the extension and \
\"_config.ml\""~docv:"CONFIG")letlibrary=Arg.(value&opt(somestring)None&info["l";"library"]~doc:"Name of the library the module under test belongs to."~absent:"INTERFACE without the file extension"~docv:"LIBRARY")letmodule_prefix=Arg.(value&opt(somestring)None&info["m";"module-prefix"]~doc:"Prefix for opening the module corresponding to FILE when it is \
part of a library that has MODULE_PREFIX as name."~docv:"MODULE_PREFIX")letsubmodule=Arg.(value&opt(somestring)None&info["s";"submodule"]~doc:"Build the qcheck-stm tests for SUBMODULE inside FILE"~docv:"SUBMODULE")letdomain=Arg.(value&flag&info["d";"domain"]~doc:"Generate STM_domain tests.")letcount=letparsei=Ok(int_of_stringi)anddocv="COUNT"inArg.(value&opt(conv~docv(parse,Fmt.(int)))1000&info["count"]~absent:"1000"~doc:"Build STM tests with COUNT test iterations.")letfork_timeout=Arg.(value&opt(someint)None&info["t";"timeout"]~doc:"Timeout for each test."~docv:"TIMEOUT")letmaininterface_fileconfig_fileocaml_outputlibrarypackage_namedune_outputmodule_prefixsubmoduledomaincountfork_timeoutgen_aliasrun_alias=letopenQcheck_stminletconfig={interface_file;config_file;ocaml_output;library;package_name;dune_output;module_prefix;submodule;domain;count;fork_timeout;gen_alias;run_alias;}inletppf=Registration.get_out_formatterdune_outputinQcheck_stm.gen_dune_rulesppfconfigletterm=Term.(constmain$interface_file$config_file$ocaml_output$library$package_name$with_stdout_to$module_prefix$submodule$domain$count$fork_timeout$gen_alias$run_alias)letcmd=Cmd.vinfotermendmoduleWrapper:sigvalcmd:unitCmd.tend=structletinfo=Cmd.info"wrapper"~doc:"Generate Dune rules for the wrapper plugin."letmaininterface_filepackage_nameocaml_outputdune_output=letopenWrapperinletconfig={interface_file;package_name;ocaml_output;dune_output}inletppf=Registration.get_out_formatterdune_outputinWrapper.gen_dune_rulesppfconfigletterm=Term.(constmain$interface_file$package_name$ocaml_output$with_stdout_to)letcmd=Cmd.vinfotermendletcmd=letinfo=Cmd.info"dune"~doc:"Generate Dune rule for ortac plugins."inCmd.groupinfo[Qcheck_stm.cmd;Wrapper.cmd]endlet()=Registration.registerPlugin.cmd