Skip to content

Commit

Permalink
Skip brick_initiator test in virtual environments
Browse files Browse the repository at this point in the history
/dev/disk/by-path does not exist in certain virtual
environments. Skip the test.

Fixes LP Bug #1196464

Change-Id: Ifc5bb061db59aaa6b7c089eda5e4eb1c9eff2dbf
  • Loading branch information
dirkmueller committed Jul 1, 2013
1 parent 066a676 commit dec8fb7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cinder/tests/test_brick_initiator.py
Expand Up @@ -248,6 +248,8 @@ def iscsi_connection(self, volume, location, iqn):
}
}

@test.testtools.skipUnless(os.path.exists('/dev/disk/by-path'),
'Test requires /dev/disk/by-path')
def test_connect_volume(self):
self.stubs.Set(os.path, 'exists', lambda x: True)
location = '10.0.2.15:3260'
Expand Down

0 comments on commit dec8fb7

Please sign in to comment.