Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
python-poetry
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
python-poetry
Commits
5dd5411e
Commit
5dd5411e
authored
Jun 03, 2020
by
thomaszub
Committed by
finswimmer
Aug 15, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed dependency name set to search string
parent
314fc27c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
2 deletions
+7
-2
poetry/console/commands/init.py
+4
-0
tests/console/commands/test_init.py
+3
-2
No files found.
poetry/console/commands/init.py
View file @
5dd5411e
...
...
@@ -262,6 +262,10 @@ The <c1>init</c1> command creates a basic <comment>pyproject.toml</> file in the
attempts
=
3
,
)
# package selected by user, set constraint name to package name
if
package
is
not
False
:
constraint
[
"name"
]
=
package
# no constraint yet, determine the best version automatically
if
package
is
not
False
and
"version"
not
in
constraint
:
question
=
self
.
create_question
(
...
...
tests/console/commands/test_init.py
View file @
5dd5411e
...
...
@@ -46,6 +46,7 @@ python = "~2.7 || ^3.6"
def
test_interactive_with_dependencies
(
app
,
repo
,
mocker
,
poetry
):
repo
.
add_package
(
get_package
(
"django-pendulum"
,
"0.1.6-pre4"
))
repo
.
add_package
(
get_package
(
"pendulum"
,
"2.0.0"
))
repo
.
add_package
(
get_package
(
"pytest"
,
"3.6.0"
))
...
...
@@ -65,8 +66,8 @@ def test_interactive_with_dependencies(app, repo, mocker, poetry):
"MIT"
,
# License
"~2.7 || ^3.6"
,
# Python
""
,
# Interactive packages
"pendulu
m
"
,
# Search for package
"
0"
,
# First option
"pendulu"
,
# Search for package
"
1"
,
# Second option is pendulum
""
,
# Do not set constraint
""
,
# Stop searching for packages
""
,
# Interactive dev packages
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment