Merge pull request #5108 from mimaki/display_preview_version

Add `preview` to version.
This commit is contained in:
Yukihiro "Matz" Matsumoto
2020-11-01 17:19:01 +09:00
committed by GitHub
2 changed files with 20 additions and 1 deletions
+19
View File
@@ -49,6 +49,24 @@ MRB_BEGIN_DECL
*/
#define MRUBY_RELEASE_TEENY 0
/*
* Patch level.
*/
#define MRUBY_PATCHLEVEL -1
/*
* Patch level string. (optional)
*/
#define MRUBY_PATCHLEVEL_STR "preview"
#ifndef MRUBY_PATCHLEVEL_STR
# if MRUBY_PATCHLEVEL < 0
# define MRUBY_PATCHLEVEL_STR "dev"
# else
# define MRUBY_PATCHLEVEL_STR "p"MRB_STRINGIZE(MRUBY_PATCHLEVEL)
# endif
#endif
/*
* The mruby version.
*/
@@ -108,6 +126,7 @@ MRB_BEGIN_DECL
*/
#define MRUBY_DESCRIPTION \
"mruby " MRUBY_VERSION \
MRUBY_PATCHLEVEL_STR \
" (" MRUBY_RELEASE_DATE ")" \
/*
+1 -1
View File
@@ -129,7 +129,7 @@ assert('mruby -r option (file not found)') do
end
assert('mruby -v option') do
ver_re = '\Amruby \d+\.\d+\.\d+ \(\d+-\d+-\d+\)\n'
ver_re = '\Amruby \d+\.\d+\.\d+.* \(\d+-\d+-\d+\)\n'
assert_mruby(/#{ver_re}\z/, "", true, %w[-v])
assert_mruby(/#{ver_re}^[^\n]*NODE.*\n:end\n\z/m, "", true, %w[-v -e p(:end)])
end