diff --git a/tcp_tests/fixtures/openstack_fixtures.py b/tcp_tests/fixtures/openstack_fixtures.py
index f69c247..ae3b9e8 100644
--- a/tcp_tests/fixtures/openstack_fixtures.py
+++ b/tcp_tests/fixtures/openstack_fixtures.py
@@ -28,13 +28,14 @@
 
 @pytest.fixture(scope='function')
 def openstack_actions(config, underlay, salt_deployed):
-    """Fixture that provides various actions for K8S
+    """Fixture that provides various actions for OpenStack
 
     :param config: fixture provides oslo.config
     :param underlay: fixture provides underlay manager
-    :rtype: K8SManager
+    :param salt_deployed: fixture provides salt manager
+    :rtype: OpenstackManager
 
-    For use in tests or fixtures to deploy a custom K8S
+    For use in tests or fixtures to deploy a custom OpenStack
     """
     return openstack_manager.OpenstackManager(config, underlay, salt_deployed)
 
@@ -52,7 +53,8 @@
     :param config: fixture provides oslo.config
     :param hardware: fixture provides enviromnet manager
     :param underlay: fixture provides underlay manager
-    :param tcp_actions: fixture provides OpenstackManager instance
+    :param common_services_deployed: fixture provides CommonServicesManager
+    :param openstack_actions: fixture provides OpenstackManager instance
     :rtype: OpenstackManager
 
     If config.openstack.openstack_installed is not set, this fixture assumes
@@ -68,54 +70,7 @@
     If you want to revert 'openstack_deployed' snapshot, please use mark:
     @pytest.mark.revert_snapshot("openstack_deployed")
     """
-    # Create Salt cluster
-    if not config.openstack.openstack_installed:
-        steps_path = config.openstack_deploy.openstack_steps_path
-        commands = underlay.read_template(steps_path)
-        openstack_actions.install(commands)
-        hardware.create_snapshot(ext.SNAPSHOT.openstack_deployed)
-
-    else:
-        # 1. hardware environment created and powered on
-        # 2. config.underlay.ssh contains SSH access to provisioned nodes
-        #    (can be passed from external config with TESTS_CONFIGS variable)
-        # 3. config.tcp.* options contain access credentials to the already
-        #    installed TCP API endpoint
-        pass
-
-    return openstack_actions
-
-
-@pytest.mark.revert_snapshot(ext.SNAPSHOT.openstack_deployed)
-@pytest.fixture(scope='function')
-def deploy_openstack(revert_snapshot, request, config,
-                     hardware, underlay, common_services_deployed,
-                     openstack_actions):
-    """Fixture to get or install OpenStack services on environment
-
-    :param revert_snapshot: fixture that reverts snapshot that is specified
-                            in test with @pytest.mark.revert_snapshot(<name>)
-    :param request: fixture provides pytest data
-    :param config: fixture provides oslo.config
-    :param hardware: fixture provides enviromnet manager
-    :param underlay: fixture provides underlay manager
-    :param tcp_actions: fixture provides OpenstackManager instance
-    :rtype: OpenstackManager
-
-    If config.openstack.openstack_installed is not set, this fixture assumes
-    that the openstack services were not installed, and do the following:
-    - install openstack services
-    - make snapshot with name 'openstack_deployed'
-    - return OpenstackManager instance
-
-    If config.openstack.openstack_installed was set, this fixture assumes that
-    the openstack services were already installed, and do the following:
-    - return OpenstackManager instance
-
-    If you want to revert 'openstack_deployed' snapshot, please use mark:
-    @pytest.mark.revert_snapshot("openstack_deployed")
-    """
-    # Create Salt cluster
+    # Deploy Openstack cluster
     if not config.openstack.openstack_installed:
         steps_path = config.openstack_deploy.openstack_steps_path
         commands = underlay.read_template(steps_path)
