diff options
author | Björn Gustavsson <[email protected]> | 2019-03-28 13:23:08 +0100 |
---|---|---|
committer | Björn Gustavsson <[email protected]> | 2019-03-28 13:23:08 +0100 |
commit | 2f879097241d289e0100c7d1725485e2276a7f70 (patch) | |
tree | dd4e273144307652a1f20445ce6a4648a3cd145a /lib/compiler/test/bs_construct_SUITE.erl | |
parent | 6258b1087db31919cfa3b34a45d99a14914a2fc6 (diff) | |
parent | 483c5c4a9860ce4866b3c4f4f545bbfa55e2e14d (diff) | |
download | otp-2f879097241d289e0100c7d1725485e2276a7f70.tar.gz otp-2f879097241d289e0100c7d1725485e2276a7f70.tar.bz2 otp-2f879097241d289e0100c7d1725485e2276a7f70.zip |
Merge branch 'bjorn/compiler/cuddle-with-tests'
* bjorn/compiler/cuddle-with-tests:
Verify the highest opcode for the r21 test suites
Add test_lib:highest_opcode/1
sys_core_fold: Simplify case_expand_var/2
beam_validator: Remove uncovered lines in lists_mod_return_type/3
Cover return type determination of lists functions
Diffstat (limited to 'lib/compiler/test/bs_construct_SUITE.erl')
-rw-r--r-- | lib/compiler/test/bs_construct_SUITE.erl | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/lib/compiler/test/bs_construct_SUITE.erl b/lib/compiler/test/bs_construct_SUITE.erl index 69017d87e7..bccd70d6cb 100644 --- a/lib/compiler/test/bs_construct_SUITE.erl +++ b/lib/compiler/test/bs_construct_SUITE.erl @@ -27,6 +27,7 @@ -export([all/0, suite/0,groups/0,init_per_suite/1, end_per_suite/1, init_per_group/2,end_per_group/2, init_per_testcase/2,end_per_testcase/2, + verify_highest_opcode/1, two/1,test1/1,fail/1,float_bin/1,in_guard/1,in_catch/1, nasty_literals/1,coerce_to_float/1,side_effect/1, opt/1,otp_7556/1,float_arith/1,otp_8054/1, @@ -43,7 +44,8 @@ all() -> groups() -> [{p,[parallel], - [two,test1,fail,float_bin,in_guard,in_catch, + [verify_highest_opcode, + two,test1,fail,float_bin,in_guard,in_catch, nasty_literals,side_effect,opt,otp_7556,float_arith, otp_8054,cover]}]. @@ -68,6 +70,20 @@ init_per_testcase(Case, Config) when is_atom(Case), is_list(Config) -> end_per_testcase(Case, Config) when is_atom(Case), is_list(Config) -> ok. +verify_highest_opcode(_Config) -> + case ?MODULE of + bs_construct_r21_SUITE -> + {ok,Beam} = file:read_file(code:which(?MODULE)), + case test_lib:highest_opcode(Beam) of + Highest when Highest =< 163 -> + ok; + TooHigh -> + ct:fail({too_high_opcode_for_21,TooHigh}) + end; + _ -> + ok + end. + two(Config) when is_list(Config) -> <<0,1,2,3,4,6,7,8,9>> = two_1([0], [<<1,2,3,4>>,<<6,7,8,9>>]), ok. |