Exemple #1
0
 def test_create_success(self):
     mover = self.get_mover_1()
     share = VNXNfsShare.create(cli=t_nas(), mover=mover, path='/EEE')
     assert_that(share.path, equal_to('/EEE'))
     assert_that(share.mover_id, equal_to(1))
     assert_that(share.existed, equal_to(True))
     assert_that(share.fs_id, equal_to(243))
Exemple #2
0
 def test_create_success(self):
     mover = self.get_mover_1()
     share = VNXNfsShare.create(cli=t_nas(), mover=mover, path='/EEE')
     assert_that(share.path, equal_to('/EEE'))
     assert_that(share.mover_id, equal_to(1))
     assert_that(share.existed, equal_to(True))
     assert_that(share.fs_id, equal_to(243))
Exemple #3
0
 def test_create_with_host_config(self):
     mover = self.get_mover_1()
     host_config = NfsHostConfig(
         root_hosts=['1.1.1.1', '2.2.2.2'],
         ro_hosts=['3.3.3.3'],
         rw_hosts=['4.4.4.4', '5.5.5.5'],
         access_hosts=['6.6.6.6'])
     share = VNXNfsShare.create(cli=t_nas(), mover=mover, path='/FFF',
                                host_config=host_config)
     assert_that(share.fs_id, equal_to(247))
     assert_that(share.path, equal_to('/FFF'))
     assert_that(share.existed, equal_to(True))
     assert_that(share.access_hosts, has_item('6.6.6.6'))
Exemple #4
0
 def test_create_with_host_config(self):
     mover = self.get_mover_1()
     host_config = NfsHostConfig(root_hosts=['1.1.1.1', '2.2.2.2'],
                                 ro_hosts=['3.3.3.3'],
                                 rw_hosts=['4.4.4.4', '5.5.5.5'],
                                 access_hosts=['6.6.6.6'])
     share = VNXNfsShare.create(cli=t_nas(),
                                mover=mover,
                                path='/FFF',
                                host_config=host_config)
     assert_that(share.fs_id, equal_to(247))
     assert_that(share.path, equal_to('/FFF'))
     assert_that(share.existed, equal_to(True))
     assert_that(share.access_hosts, has_item('6.6.6.6'))
Exemple #5
0
 def f():
     mover = self.get_mover_1()
     VNXNfsShare.create(cli=t_nas(), mover=mover, path='/invalid')
Exemple #6
0
 def f():
     mover = self.get_mover_1()
     VNXNfsShare.create(cli=t_nas(), mover=mover, path='/invalid')