def assert_bool_op_api(opname, bool_frame_with_na, float_string_frame,<EOL>has_bool_only=False):
<EOL>mixed = float_string_frame<EOL>mixed['<STR_LIT>'] = np.random.randn(len(mixed)) > <NUM_LIT:0.5><EOL>getattr(mixed, opname)(axis=<NUM_LIT:0>)<EOL>getattr(mixed, opname)(axis=<NUM_LIT:1>)<EOL>if has_bool_only:<EOL><INDENT>getattr(mixed, opname)(axis=<NUM_LIT:0>, bool_only=True)<EOL>getattr(mixed, opname)(axis=<NUM_LIT:1>, bool_only=True)<EOL>getattr(bool_frame_with_na, opname)(axis=<NUM_LIT:0>, bool_only=False)<EOL>getattr(bool_frame_with_na, opname)(axis=<NUM_LIT:1>, bool_only=False)<EOL><DEDENT>
Check that API for boolean operator opname works as advertised on frame

Parameters
----------
opname : string
    Name of the operator to test on frame
float_frame : DataFrame
    DataFrame with columns of type float
float_string_frame : DataFrame
    DataFrame with both float and string columns
has_bool_only : bool, default False
    Whether the method "opname" has the kwarg "bool_only"