File tree Expand file tree Collapse file tree
static_vm_package/VCenterAutoloadStaticVMDriver/tests Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ after_success : coveralls
2+ env :
3+ - CLOUD_SHELL_SHELL_CORE=1
4+ - CLOUD_SHELL_SHELL_CORE=2
5+ install :
6+ - pip install -r external_requirements.txt
7+ - pip install -r test_requirements.txt
8+ - pip install "cloudshell-core>=2.0.0,<2.1.0" --extra-index-url https://testpypi.python.org/simple
9+ - chmod 777 ./cloudshell_shell_core_install.sh
10+ - ./cloudshell_shell_core_install.sh
11+ - pip install "cloudshell-automation-api>=7.1.0.0,<7.2.0.0" --extra-index-url https://testpypi.python.org/simple
112language : python
2- python :
3- - " 2.7"
4-
5- install :
6- - pip install -r external_requirements.txt
7- - pip install -r test_requirements.txt
8- - pip install "cloudshell-core>=2.0.0,<2.1.0" --extra-index-url https://testpypi.python.org/simple
9- - pip install "cloudshell-shell-core>=2.0.0,<2.1.0" --extra-index-url https://testpypi.python.org/simple
10- - pip install "cloudshell-automation-api>=7.1.0.0,<7.2.0.0" --extra-index-url https://testpypi.python.org/simple
11-
12- script :
13- - pushd package
14- - python setup.py develop
15- - popd
16- - python runtests.py --with-coverage --cover-package=package --exclude-dir=integration
17-
18- after_success :
19- coveralls
20-
21- notifications :
22- webhools : https://qualisystems.getbadges.io/api/app/webhook/63350e33-4119-49c3-8127-075aaa022926
13+ notifications :
14+ webhools : " https://qualisystems.getbadges.io/api/app/webhook/63350e33-4119-49c3-8127-075aaa022926"
15+ python :
16+ - " 2.7"
17+ script :
18+ - pushd package
19+ - python setup.py develop
20+ - popd
21+ - chmod 777 ./run_static_or_vcenter_tests.sh
22+ - ./run_static_or_vcenter_tests.sh
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ if [ " ${CLOUD_SHELL_SHELL_CORE} " -eq 1 ]
3+ then
4+ pip install " cloudshell-shell-core>=2.0.0,<2.1.0" --extra-index-url https://testpypi.python.org/simple
5+ else
6+ pip install " cloudshell-shell-core>=2.4.0,<2.5.0" --extra-index-url https://testpypi.python.org/simple
7+ fi
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ if [ " ${CLOUD_SHELL_SHELL_CORE} " -eq 1 ]
3+ then
4+ echo " Running vCenter Tests"
5+ python runtests.py --with-coverage --cover-package=package --exclude-dir=integration
6+ else
7+ echo " Running static VM Tests"
8+ python runtestsStaticVM.py --with-coverage --cover-package=package --exclude-dir=integration
9+ fi
Original file line number Diff line number Diff line change 1+ import re
12import nose
23import nose .config
34import sys
45from nose .plugins .manager import DefaultPluginManager
56c = nose .config .Config ()
67c .plugins = DefaultPluginManager ()
78c .srcDirs = ['package' ]
9+
10+
11+ # c.ignoreFiles.append('vm_autoload_driver')
12+ c .ignoreFiles .append (re .compile (r'^vm_autoload_driver\.py$' ))
13+ c .ignoreFiles .append (re .compile (r'^test_get_inventory\.py$' ))
14+ c .ignoreFiles .append (re .compile (r'^DeployAppOrchestrationDriver$' ))
15+
16+
817if not nose .run (config = c ):
918 sys .exit (1 )
Original file line number Diff line number Diff line change 1+ import nose
2+ import nose .config
3+ import sys
4+ from nose .plugins .manager import DefaultPluginManager
5+ c = nose .config .Config ()
6+ c .plugins = DefaultPluginManager ()
7+ c .srcDirs = ['static_vm_package' ]
8+ if not nose .run (config = c ):
9+ sys .exit (1 )
Original file line number Diff line number Diff line change @@ -45,6 +45,8 @@ def test_get_inventory(self):
4545 self .assertTrue (self .deploy_app_orchestration_driver ._try_get_ip .called )
4646 self .assertTrue (self .deploy_app_orchestration_driver ._get_vm_details .called )
4747 self .assertTrue (self .deploy_app_orchestration_driver .pv_service .find_vm_by_name .called )
48+
49+
4850
4951 def test_get_vm_details (self ):
5052 vm_details = self .deploy_app_orchestration_driver ._get_vm_details (uuid = "Piplup" ,
@@ -56,3 +58,4 @@ def test_get_vm_details(self):
5658
5759
5860
61+
Original file line number Diff line number Diff line change 1+ [Packaging]
2+ is_driver: True
3+ driver_folder: static_vm_autoload_driver
4+ include_dirs:
5+ target_name: VCenter Static VM Autoload
6+ target_dir: Resource Drivers - Python
You can’t perform that action at this time.
0 commit comments