docs/sigs.md in rbs-0.3.1 vs docs/sigs.md in rbs-0.4.0

- old
+ new

@@ -14,11 +14,11 @@ See [syntax guide](syntax.md). ## Testing signatures When you finish writing signature, you may want to test the signature. -ruby-signature provides a feature to test your signature. +rbs provides a feature to test your signature. ``` $ RBS_TEST_TARGET='Foo::*' bundle exec ruby -r rbs/test/setup test/foo_test.rb ``` @@ -66,11 +66,11 @@ ``` ### UnresolvedOverloadingError The error means there is a type error on overloaded methods. -The `ruby-signature` test framework tries to the best error message for overloaded methods too, but it reports the `UnresolvedOverloadingError` when it fails. +The `rbs` test framework tries to the best error message for overloaded methods too, but it reports the `UnresolvedOverloadingError` when it fails. ## Setting up the test The design of the signature testing aims to be non-intrusive. The setup is done in two steps: @@ -82,17 +82,17 @@ You need to require `rbs/test/setup` for signature testing. You can do it using `-r` option through command line argument or the `RUBYOPT` environment variable. ``` $ ruby -r rbs/test/setup run_tests.rb -$ RUBYOPT='-rruby/signature/test/setup' rake test +$ RUBYOPT='-rrbs/test/setup' rake test ``` When you are using Bundler, you may need to require `bundler/setup` explicitly. ``` -$ RUBYOPT='-rbundler/setup -rruby/signature/test/setup' bundle exec rake test +$ RUBYOPT='-rbundler/setup -rrbs/test/setup' bundle exec rake test ``` ### Environment variables You need to specify `RBS_TEST_TARGET` to run the test, and you can customize the test with the following environment variables. @@ -107,11 +107,11 @@ - `RBS_TEST_TARGET=Foo::Bar,Foo::Baz` comma separated exact class names - `RBS_TEST_TARGET=Foo::*` using wildcard `RBS_TEST_SKIP` is to skip some of the classes which matches with `RBS_TEST_TARGET`. -`RBS_TEST_OPT` is to pass the options for ruby signature handling. +`RBS_TEST_OPT` is to pass the options for rbs handling. You may need to specify `-r` or `-I` to load signatures. The default is `-I sig`. ``` RBS_TEST_OPT='-r set -r pathname -I sig' @@ -129,10 +129,10 @@ $ RBS_TEST_LOGLEVEL=error \ RBS_TEST_TARGET='Kaigi::*' \ RBS_TEST_SKIP='Kaigi::MonkeyPatch' \ RBS_TEST_OPT='-rset -rpathname -Isig -Iprivate' \ RBS_TEST_RAISE=true \ - RUBYOPT='-rbundler/setup -rruby/signature/test/setup' \ + RUBYOPT='-rbundler/setup -rrbs/test/setup' \ bundle exec rake test ``` ## Testing tips