'Ensure write concern can be specified in connect() via
a kwarg or as part of the connection URI.'

def test_write_concern(self):

    conn1 = connect(alias='conn1', host='mongodb://localhost/testing?w=1&j=true')
    conn2 = connect('testing', alias='conn2', w=1, j=True)
    if IS_PYMONGO_3:
        self.assertEqual(conn1.write_concern.document, {'w': 1, 'j': True})
        self.assertEqual(conn2.write_concern.document, {'w': 1, 'j': True})
    else:
        self.assertEqual(dict(conn1.write_concern), {'w': 1, 'j': True})
        self.assertEqual(dict(conn2.write_concern), {'w': 1, 'j': True})
