'Test the conv atom.'

def test_conv(self):

    a = np.ones((3, 1))
    b = Parameter(2, sign='positive')
    expr = conv(a, b)
    assert expr.is_positive()
    self.assertEqual(expr.size, (4, 1))
    b = Parameter(2, sign='negative')
    expr = conv(a, b)
    assert expr.is_negative()
    with self.assertRaises(Exception) as cm:
        conv(self.x, (-1))
    self.assertEqual(str(cm.exception), 'The    first    argument    to    conv    must    be    constant.')
    with self.assertRaises(Exception) as cm:
        conv([[0, 1], [0, 1]], self.x)
    self.assertEqual(str(cm.exception), 'The    arguments    to    conv    must    resolve    to    vectors.')
