diff --git a/poetry/test_linux.sh b/poetry/test_linux.sh index fb205ee6a..577907dbc 100755 --- a/poetry/test_linux.sh +++ b/poetry/test_linux.sh @@ -7,6 +7,8 @@ if [[ $is_ubuntu_os == true ]]; then apt install -y clang libmysqlclient-dev fi +readme_content='test readme content' + pyproject_content=' [tool.poetry] name = "StandaloneTools" @@ -30,14 +32,16 @@ Resolving dependencies... Package operations: 6 installs, 0 updates, 0 removals - • Installing certifi (2023.5.7) - • Installing charset-normalizer (3.1.0) + • Installing certifi (2023.11.17) + • Installing charset-normalizer (3.3.2) • Installing idna (3.4) - • Installing urllib3 (1.26.16) + • Installing urllib3 (1.26.18) • Installing mysqlclient (2.1.1) • Installing requests (2.28.2) -Writing lock file' +Writing lock file + +Installing the current project: StandaloneTools (1.0.0)' test_version() { assertEquals "Poetry (version 1.7.1)" "$(../bin/poetry.sh --version)" @@ -51,18 +55,21 @@ test_version_plugins() { Dependencies - poetry (>=1.2.0,<2.0.0) - • poetry-plugin-export (1.4.0) Poetry plugin to export the dependencies to various formats + • poetry-plugin-export (1.6.0) Poetry plugin to export the dependencies to various formats 1 application plugin Dependencies - - poetry (>=1.5.0,<2.0.0) - - poetry-core (>=1.6.0,<2.0.0)" "$(../bin/poetry.sh self show plugins)" + - poetry (>=1.6.0,<2.0.0) + - poetry-core (>=1.7.0,<2.0.0)" "$(../bin/poetry.sh self show plugins)" } test_install_from_symlink() { { printf '%s' "$pyproject_content" } > pyproject.toml + { printf '%s' "$readme_content" + } > README.md + ln -sf "$(readlink -f ../bin/poetry.sh)" /usr/local/bin/poetry assertEquals "$poetry_install_stdout" "$(poetry install)" @@ -72,9 +79,12 @@ test_install_from_sh() { { printf '%s' "$pyproject_content" } > pyproject.toml + { printf '%s' "$readme_content" + } > README.md + assertEquals "Installing dependencies from lock file -No dependencies to install or update" "$(../bin/poetry.sh install)" +No dependencies to install or update" "$(../bin/poetry.sh install --no-root)" } # Load and run shUnit2. diff --git a/poetry/test_windows.sh b/poetry/test_windows.sh index 3f30d6823..efce5bc9a 100755 --- a/poetry/test_windows.sh +++ b/poetry/test_windows.sh @@ -3,6 +3,8 @@ is_windows_os=false && [[ $(uname) == Windows_NT* ]] && is_windows_os=true is_nanoserver_os=false && $is_windows_os && [[ ! -f "C:\Windows\notepad.exe" ]] && is_nanoserver_os=true +readme_content='test readme content' + pyproject_content=' [tool.poetry] name = "StandaloneTools" @@ -35,6 +37,9 @@ test_install_from_path() { { printf '%s' "$pyproject_content" } > pyproject.toml + { printf '%s' "$readme_content" + } > README.md + path_with_poetry="$PATH;$(readlink -f ../bin)" export PATH="$path_with_poetry" @@ -47,9 +52,12 @@ test_install_from_bat() { { printf '%s' "$pyproject_content" } > pyproject.toml + { printf '%s' "$readme_content" + } > README.md + assertEquals "Installing dependencies from lock file -No dependencies to install or update" "$(../bin/poetry.bat install | dos2unix)" +No dependencies to install or update" "$(../bin/poetry.bat install --no-root | dos2unix)" } # Load and run shUnit2.