def ifexp_node(draw, test=const_node(hs.booleans()), body=const_node(), orelse=const_node()): test = draw(test) body = draw(body) orelse = draw(orelse) node = astroid.IfExp() node.postinit(test, body, orelse) return node
def ifexp_node(draw, test=const_node(hs.booleans()), expr=const_node(), orelse=const_node()): # TODO: Add an option for whether expr and orelse strategies produce the same type. test = draw(test) expr = draw(expr) node = astroid.IfExp() node.postinit(test, expr, expr) return node