Ignore:
Timestamp:
08/22/08 19:01:40 (4 years ago)
Author:
dom
Message:

Add support for -test attribute with explicit list (not exports).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/tests_test.erl

    r34 r35  
    88 
    99filter_by_attribute () -> 
    10     filtering_non_tests_returns_empty_list(), 
    11     filtering_tests_returns_list_of_tests_from_unloaded_binary (), 
     10    non_tests_returns_empty_list(), 
     11    test_exports_returns_list_of_tests_from_unloaded_binary (), 
     12    test_non_exports_also (), 
    1213    ok. 
    1314 
    14 filtering_non_tests_returns_empty_list () -> 
     15non_tests_returns_empty_list () -> 
    1516    Binary = modules: to_binary ("../fix/eg_code.erl"), 
    1617    {eg_code, []} = tests: filter_by_attribute (Binary). 
    1718 
    18 filtering_tests_returns_list_of_tests_from_unloaded_binary () -> 
     19test_exports_returns_list_of_tests_from_unloaded_binary () -> 
    1920    File = "../fix/eg_test.erl", 
    2021    Binary = modules: to_binary (File), 
     
    2223    {eg_test, [ok, nok]} = tests: filter_by_attribute (Binary), 
    2324    false = code: is_loaded (eg_test). 
     25 
     26test_non_exports_also () -> 
     27    File = "../fix/eg_test_not_exports.erl", 
     28    Binary = modules: to_binary (File), 
     29    false = code: is_loaded (eg_test_not_exports), 
     30    {eg_test_not_exports, [ok]} = tests: filter_by_attribute (Binary), 
     31    false = code: is_loaded (eg_test_not_exports). 
Note: See TracChangeset for help on using the changeset viewer.