[ruby] add a test for null shared_ptr in containers.
This commit is contained in:
parent
661c3fc554
commit
0c3298073b
2 changed files with 63 additions and 0 deletions
|
|
@ -0,0 +1,15 @@
|
|||
require "cpp11_shared_ptr_nullptr_in_containers"
|
||||
|
||||
include Cpp11_shared_ptr_nullptr_in_containers
|
||||
|
||||
a = ret_vec_c_shared_ptr()
|
||||
raise unless a[0].get_m == 0
|
||||
raise unless a[1] == nil
|
||||
raise unless a[2].get_m == 2
|
||||
|
||||
a = ret_arg_vec([C.new(7), nil, C.new(9)])
|
||||
raise unless a[0].get_m == 7
|
||||
raise unless a[1] == nil
|
||||
raise unless a[2].get_m == 9
|
||||
|
||||
raise unless is_last_null([C.new(7), C.new(8), nil])
|
||||
Loading…
Add table
Add a link
Reference in a new issue