def install(self): current_path = os.getcwd() shell_package = ShellPackage(current_path) if shell_package.is_layer_one(): click.secho("Installing a L1 shell directly via shellfoundry is not supported. " "Please follow the L1 shell import procedure described in help.quali.com.", fg="yellow") else: if shell_package.is_tosca(): self.shell_package_installer.install(current_path) else: self._install_old_school_shell() click.secho('Successfully installed shell', fg='green')
def pack(self): current_path = os.getcwd() shell_package = ShellPackage(current_path) if shell_package.is_layer_one(): click.secho( "Packaging a L1 shell directly via shellfoundry is not supported.", fg="yellow") elif shell_package.is_tosca(): self.shell_package_builder.pack(current_path) else: self._pack_old_school_shell(current_path)
def test_is_layer_one(self): # Arrange shell_package = ShellPackage('work/folders/cloudshell-L1-test') # Assert self.assertTrue(shell_package.is_layer_one())