def _hv_switch(op, expected_function):
 class XStackTester(_HVStackTester, ):
  op_class = op
  def expected_f(self, a, format=None, dtype=None):
   return expected_function(a, format, dtype)
 XStackTester.__name__ = (op.__name__ + 'Tester')
 if hasattr(XStackTester, '__qualname__'):
  XStackTester.__qualname__ = XStackTester.__name__
 return XStackTester

def _hv_switch ( op , expected_function ) : class XStackTester ( _HVStackTester , ) : op_class = op def expected_f ( self , a , format = None , dtype = None ) : return expected_function ( a , format , dtype ) XStackTester . __name__ = ( op . __name__ + 'Tester' ) if hasattr ( XStackTester , '__qualname__' ) : XStackTester . __qualname__ = XStackTester . __name__ return XStackTester
return the right test class for hstack or vstack .