##==============================================================================
#    Copyright (c) 2003-2006 Joel de Guzman
#    Copyright (c) 2013 Mateusz Loskot
#    Copyright (c) 2014-2018 Kohei Takahashi
#
#   Use, modification and distribution is subject to the Boost Software
#   License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
#   http://www.boost.org/LICENSE_1_0.txt)
#==============================================================================
# bring in rules for testing
import testing ;
import os ;
import ../../config/checks/config : requires ;

if [ os.environ CI ]
{
    CI_DEFINES = <define>CI_SKIP_KNOWN_FAILURE=1 ;
}

project
    : requirements
        $(CI_DEFINES)
    ;

{
    test-suite fusion :

    [ run algorithm/all.cpp ]
    [ run algorithm/any.cpp ]
    [ run algorithm/clear.cpp ]
    [ run algorithm/copy.cpp ]
    [ run algorithm/count.cpp ]
    [ run algorithm/count_if.cpp ]
    [ run algorithm/erase.cpp ]
    [ run algorithm/erase_key.cpp ]
    [ run algorithm/filter.cpp ]
    [ run algorithm/filter_if.cpp ]
    [ run algorithm/find.cpp ]
    [ run algorithm/find_if.cpp ]
    [ run algorithm/fold.cpp ]
    [ run algorithm/for_each.cpp ]
    [ run algorithm/insert.cpp ]
    [ run algorithm/insert_range.cpp ]
    [ run algorithm/iter_fold.cpp ]
    [ run algorithm/move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run algorithm/none.cpp ]
    [ run algorithm/pop_back.cpp ]
    [ run algorithm/pop_front.cpp ]
    [ run algorithm/push_back.cpp ]
    [ run algorithm/push_front.cpp ]
    [ run algorithm/remove.cpp ]
    [ run algorithm/remove_if.cpp ]
    [ run algorithm/replace.cpp ]
    [ run algorithm/replace_if.cpp ]
    [ run algorithm/reverse_fold.cpp ]
    [ run algorithm/reverse_iter_fold.cpp ]
    [ run algorithm/reverse.cpp ]
    [ run algorithm/segmented_for_each.cpp ]
    [ run algorithm/segmented_find.cpp ]
    [ run algorithm/segmented_find_if.cpp ]
    [ run algorithm/segmented_fold.cpp ]
    [ run algorithm/transform.cpp ]
    [ run algorithm/join.cpp ]
    [ run algorithm/zip.cpp ]
    [ run algorithm/zip2.cpp ]
    [ run algorithm/zip_ignore.cpp ]
    [ run algorithm/flatten.cpp ]
    [ compile algorithm/ticket-5490.cpp ]

    [ run sequence/as_deque.cpp ]
    [ run sequence/as_list.cpp ]
    [ run sequence/as_map.cpp ]
    [ run sequence/as_map_assoc.cpp ]
    [ run sequence/as_set.cpp ]
    [ run sequence/as_vector.cpp ]
    [ run sequence/boost_tuple.cpp ]
    [ run sequence/boost_tuple_iterator.cpp ]
    [ run sequence/cons.cpp ]
    [ run sequence/convert_boost_tuple.cpp ]
    [ run sequence/convert_deque.cpp ]
    [ run sequence/convert_list.cpp ]
    [ run sequence/convert_std_pair.cpp ]
    [ run sequence/convert_std_tuple.cpp : :
        : [ requires cxx11_variadic_templates cxx11_hdr_tuple ] ]
    [ run sequence/convert_vector.cpp ]
    [ run sequence/filter_view.cpp ]
    [ run sequence/hash.cpp ]
    [ run sequence/io.cpp ]
    [ run sequence/iterator_range.cpp ]
    [ run sequence/joint_view.cpp ]
    [ run sequence/list_comparison.cpp ]
    [ run sequence/list_construction.cpp ]
    [ run sequence/list_copy.cpp ]
    [ run sequence/list_iterator.cpp ]
    [ run sequence/list_hash.cpp ]
    [ run sequence/list_make.cpp ]
    [ run sequence/list_misc.cpp ]
    [ run sequence/list_mutate.cpp ]
    [ run sequence/list_nest.cpp ]
    [ run sequence/list_tie.cpp ]
    [ run sequence/list_value_at.cpp ]
    [ run sequence/deque_comparison.cpp ]
    [ run sequence/deque_construction.cpp ]
    [ run sequence/deque_copy.cpp ]
    [ run sequence/deque_iterator.cpp ]
    [ run sequence/deque_hash.cpp ]
    [ compile sequence/deque_is_constructible.cpp ]
    [ run sequence/deque_make.cpp ]
    [ run sequence/deque_misc.cpp ]
    [ run sequence/deque_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/deque_mutate.cpp ]
    [ run sequence/deque_nest.cpp ]
    [ run sequence/deque_tie.cpp ]
    [ run sequence/deque_value_at.cpp ]
    [ run sequence/front_extended_deque.cpp ]
    [ run sequence/back_extended_deque.cpp ]
    [ run sequence/make_list.cpp ]
    [ run sequence/make_vector.cpp ]
    [ run sequence/map.cpp ]
    [ run sequence/map_comparison.cpp ]
    [ run sequence/map_construction.cpp ]
    [ run sequence/map_copy.cpp ]
    [ run sequence/map_misc.cpp ]
    [ run sequence/map_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/map_mutate.cpp ]
    [ run sequence/map_tie.cpp ]
    [ run sequence/nil.cpp ]
    [ run sequence/nview.cpp ]
    [ run sequence/reverse_view.cpp ]
    [ run sequence/segmented_iterator_range.cpp ]
    [ run sequence/set.cpp ]
    [ run sequence/single_view.cpp ]
    [ run sequence/std_pair.cpp ]
    [ run sequence/boost_array.cpp ]
    [ run sequence/array.cpp ]
    [ run sequence/std_array.cpp : :
        : [ requires cxx11_hdr_array ] ]
    [ run sequence/tuple_comparison.cpp ]
    [ run sequence/tuple_construction.cpp ]
    [ run sequence/tuple_conversion.cpp ]
    [ run sequence/tuple_copy.cpp ]
    [ run sequence/tuple_element.cpp ]
    [ run sequence/tuple_make.cpp ]
    [ run sequence/tuple_misc.cpp ]
    [ run sequence/tuple_mutate.cpp ]
    [ run sequence/tuple_nest.cpp ]
    [ run sequence/tuple_hash.cpp ]
    [ run sequence/tuple_tie.cpp ]
    [ run sequence/tuple_traits.cpp : :
        :
        : tuple_traits__maybe_variadic ]
    [ run sequence/tuple_traits.cpp : :
        : <define>BOOST_FUSION_DISABLE_VARIADIC_VECTOR
        : tuple_traits__no_variadic ]
    [ run sequence/transform_view.cpp ]
    [ run sequence/vector_comparison.cpp ]
    [ run sequence/vector_construction.cpp ]
    [ run sequence/vector_conversion.cpp ]
    [ run sequence/vector_copy.cpp ]
    [ run sequence/vector_iterator.cpp ]
    [ run sequence/vector_make.cpp ]
    [ run sequence/vector_misc.cpp ]
    [ run sequence/vector_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/vector_mutate.cpp ]
    [ run sequence/vector_n.cpp ]
    [ run sequence/vector_nest.cpp ]
    [ run sequence/vector_hash.cpp ]
    [ run sequence/vector_tie.cpp ]
    [ run sequence/vector_traits.cpp : :
        :
        : vector_traits__maybe_variadic ]
    [ run sequence/vector_traits.cpp : :
        : <define>BOOST_FUSION_DISABLE_VARIADIC_VECTOR
        : vector_traits__no_variadic ]
    [ run sequence/vector_value_at.cpp ]
    [ run sequence/zip_view.cpp ]
    [ run sequence/zip_view2.cpp ]
    [ run sequence/zip_view_ignore.cpp ]
    [ run sequence/repetitive_view.cpp ]
    [ run sequence/deduce_sequence.cpp ]
    [ run sequence/adapt_adt_named.cpp ]
    [ run sequence/adapt_adt_named_empty.cpp ]
    [ run sequence/adapt_adt.cpp ]
    [ run sequence/adapt_adt_empty.cpp ]
    [ run sequence/adapt_assoc_adt_named.cpp ]
    [ run sequence/adapt_assoc_adt_named_empty.cpp ]
    [ run sequence/adapt_assoc_adt.cpp ]
    [ run sequence/adapt_assoc_adt_empty.cpp ]
    [ run sequence/adapt_assoc_struct_named.cpp ]
    [ run sequence/adapt_assoc_struct_named_empty.cpp ]
    [ run sequence/adapt_assoc_struct.cpp ]
    [ run sequence/adapt_assoc_struct_empty.cpp ]
    [ run sequence/adapt_assoc_tpl_adt.cpp ]
    [ run sequence/adapt_assoc_tpl_adt_empty.cpp ]
    [ run sequence/adapt_assoc_tpl_struct.cpp ]
    [ run sequence/adapt_assoc_tpl_struct_empty.cpp ]
    [ run sequence/adapt_struct_named.cpp ]
    [ run sequence/adapt_struct_named_empty.cpp ]
    [ run sequence/adapt_struct.cpp ]
    [ run sequence/adapt_struct_empty.cpp ]
    [ run sequence/adapt_tpl_adt.cpp ]
    [ run sequence/adapt_tpl_adt_empty.cpp ]
    [ run sequence/adapt_tpl_struct.cpp ]
    [ run sequence/adapt_tpl_struct_empty.cpp ]
    [ run sequence/adt_attribute_proxy.cpp ]
    [ run sequence/define_struct.cpp ]
    [ run sequence/define_struct_empty.cpp ]
    [ run sequence/define_struct_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/define_struct_inline.cpp ]
    [ run sequence/define_struct_inline_empty.cpp ]
    [ run sequence/define_struct_inline_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/define_assoc_struct.cpp ]
    [ run sequence/define_assoc_struct_empty.cpp ]
    [ run sequence/define_assoc_struct_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/define_tpl_struct.cpp ]
    [ run sequence/define_tpl_struct_empty.cpp ]
    [ run sequence/define_tpl_struct_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/define_tpl_struct_inline.cpp ]
    [ run sequence/define_tpl_struct_inline_empty.cpp ]
    [ run sequence/define_tpl_struct_inline_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/define_assoc_tpl_struct.cpp ]
    [ run sequence/define_assoc_tpl_struct_empty.cpp ]
    [ run sequence/define_assoc_tpl_struct_move.cpp : :
        : [ requires cxx11_rvalue_references ] ]
    [ run sequence/std_tuple.cpp : :
        : [ requires cxx11_variadic_templates cxx11_hdr_tuple ] ]
    [ run sequence/std_tuple_iterator.cpp : :
        : [ requires cxx11_variadic_templates cxx11_hdr_tuple ] ]
    [ run sequence/ref_vector.cpp ]
    [ run sequence/flatten_view.cpp ]
    [ compile sequence/github-159.cpp ]
    [ run sequence/github-176.cpp ]

    [ compile sequence/size.cpp ]

    [ run functional/fused.cpp ]
    [ run functional/fused_function_object.cpp ]
    [ run functional/fused_procedure.cpp ]
    [ run functional/unfused.cpp ]
    [ run functional/unfused_typed.cpp ]
    [ run functional/make_fused.cpp ]
    [ run functional/make_fused_function_object.cpp ]
    [ run functional/make_fused_procedure.cpp ]
    [ run functional/make_unfused.cpp ]
    [ run functional/invoke.cpp ]
    [ run functional/invoke_function_object.cpp ]
    [ run functional/invoke_procedure.cpp ]
    [ run sequence/swap.cpp ]

    [ compile support/is_sequence.cpp ]
    [ compile support/is_view.cpp ]
    [ compile support/pair_deque.cpp ]
    [ compile support/pair_list.cpp ]
    [ compile support/pair_map.cpp ]
    [ compile support/pair_set.cpp ]
    [ compile support/pair_vector.cpp ]
    [ compile support/pair_nest.cpp ]
    [ compile support/index_sequence.cpp
        : [ requires cxx11_variadic_templates ] ]
    [ compile support/and.cpp
        : [ requires cxx11_variadic_templates ] ]
    [ compile support/tag_of.cpp ]
    [ compile support/unused.cpp ]

#   [ compile-fail xxx.cpp  ]

    ;
}
