aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/test/re_SUITE.erl
diff options
context:
space:
mode:
authorRickard Green <[email protected]>2017-04-18 17:21:41 +0200
committerGitHub <[email protected]>2017-04-18 17:21:41 +0200
commit6124bfc9b61227a5e82f1d7273d0895e909aac6e (patch)
treeb2a3c2c9d61919526a3fba06b505be079ef29467 /lib/stdlib/test/re_SUITE.erl
parent9e104d8cb7bf78088ed7fb06e1824a299d31c0bc (diff)
parent56c2f180bec77bd17529d61cb65d1884550fcb17 (diff)
downloadotp-6124bfc9b61227a5e82f1d7273d0895e909aac6e.tar.gz
otp-6124bfc9b61227a5e82f1d7273d0895e909aac6e.tar.bz2
otp-6124bfc9b61227a5e82f1d7273d0895e909aac6e.zip
Merge pull request #1412 from manuel-rubio/manuel-rubio/add-re-version
Add re:version/0 OTP-14347
Diffstat (limited to 'lib/stdlib/test/re_SUITE.erl')
-rw-r--r--lib/stdlib/test/re_SUITE.erl14
1 files changed, 11 insertions, 3 deletions
diff --git a/lib/stdlib/test/re_SUITE.erl b/lib/stdlib/test/re_SUITE.erl
index a76ded5f60..71f86e32e5 100644
--- a/lib/stdlib/test/re_SUITE.erl
+++ b/lib/stdlib/test/re_SUITE.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 2008-2016. All Rights Reserved.
+%% Copyright Ericsson AB 2008-2017. All Rights Reserved.
%%
%% Licensed under the Apache License, Version 2.0 (the "License");
%% you may not use this file except in compliance with the License.
@@ -24,7 +24,7 @@
run_options/1,combined_options/1,replace_autogen/1,
global_capture/1,replace_input_types/1,replace_return/1,
split_autogen/1,split_options/1,split_specials/1,
- error_handling/1,pcre_cve_2008_2371/1,
+ error_handling/1,pcre_cve_2008_2371/1,re_version/1,
pcre_compile_workspace_overflow/1,re_infinite_loop/1,
re_backwards_accented/1,opt_dupnames/1,opt_all_names/1,inspect/1,
opt_no_start_optimize/1,opt_never_utf/1,opt_ucp/1,
@@ -45,7 +45,7 @@ all() ->
pcre_compile_workspace_overflow, re_infinite_loop,
re_backwards_accented, opt_dupnames, opt_all_names,
inspect, opt_no_start_optimize,opt_never_utf,opt_ucp,
- match_limit, sub_binaries].
+ match_limit, sub_binaries, re_version].
groups() ->
[].
@@ -194,6 +194,14 @@ run_options(Config) when is_list(Config) ->
+%% Test the version is retorned correctly
+re_version(_Config) ->
+ Version = re:version(),
+ {match,[Version]} = re:run(Version,"^[0-9]\\.[0-9]{2} 20[0-9]{2}-[0-9]{2}-[0-9]{2}",[{capture,all,binary}]),
+ ok.
+
+
+
%% Test compile options given directly to run.
combined_options(Config) when is_list(Config) ->
ok = crtest("ABDabcdABCD","abcd",[],true,{match,[{3,4}]}),