def build_optproblem_list(include=[], exclude=[]):
    """Builds a list of optproblems.
    
    include: (optional) list of optproblems names
        The names of the optproblems to test. Only optproblems in this list 
        will be tested. Each name should be just the class name (e.g., 'SellarProblem'). 
        Must be set to None if excludes is specified. If not specified, 
        all OptProblems, except those in exclude, are used. 
    
    exclude: (optional) list of optproblems names
        The names of the optproblems not to test. All optproblems from
        openmdao.lib.optproblems will be tested except for the ones in this 
        list. Each name should just be the class name (e.g., 'SellarProblem'). 
        Must be set to None if includes is specified. 
    """
    
    if include and exclude: 
        raise ValueError("Can't set both include and exlude for OptProblems")
    
    startdirs = [os.path.dirname(openmdao.lib.optproblems.__file__),
                 os.path.dirname(component.__file__)]
    psta = PythonSourceTreeAnalyser(startdirs, os.path.join('*','test','*'))    
    opt_problems = psta.find_inheritors("openmdao.main.problem_formulation.OptProblem")
    
    probs = []
    for prob_name in opt_problems: 
            prob_class = prob_name.split(".")[-1]
            prob_package = ".".join(prob_name.split(".")[:-1])
            if  (not include and not exclude) or (include and include in prob_class) or \
                (exclude and prob_class not in exclude): 
                
                prob_package = __import__(prob_package,globals(),locals(),[prob_class,],-1)
                probs.append(getattr(prob_package,prob_class)()) #create instance of the OptProblem

    return probs
dataset/ETHPy150Open OpenMDAO/OpenMDAO-Framework/openmdao.lib/src/openmdao/lib/architectures/mdao_test_suite.py/build_optproblem_list/swapped operands of `in`