Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Populate UI fields with -c, -r, --step-clients, and --step-time options #1339

Merged
merged 12 commits into from
Apr 21, 2020

Conversation

Trouv
Copy link
Contributor

@Trouv Trouv commented Apr 19, 2020

Closes #1186

I had trouble thinking of test cases to write for this (I did write one), so if you have any ideas please let me know!

@codecov
Copy link

codecov bot commented Apr 19, 2020

Codecov Report

Merging #1339 into master will decrease coverage by 0.28%.
The diff coverage is 33.33%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1339      +/-   ##
==========================================
- Coverage   81.06%   80.78%   -0.29%     
==========================================
  Files          24       24              
  Lines        2234     2243       +9     
  Branches      339      342       +3     
==========================================
+ Hits         1811     1812       +1     
- Misses        333      341       +8     
  Partials       90       90              
Impacted Files Coverage Δ
locust/argument_parser.py 75.00% <ø> (ø)
locust/main.py 20.10% <0.00%> (-0.63%) ⬇️
locust/web.py 91.01% <ø> (-0.57%) ⬇️
locust/env.py 95.55% <100.00%> (+0.31%) ⬆️
locust/contrib/fasthttp.py 87.04% <0.00%> (-0.52%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1595029...8c14910. Read the comment docs.

@Trouv
Copy link
Contributor Author

Trouv commented Apr 19, 2020

I also noticed that web_port and web_host are not used in master right now. Should I go ahead and fix this in this PR or should there be a separate one?

@heyman
Copy link
Member

heyman commented Apr 19, 2020

I'm not sure about adding four extra parameters to the create_web_ui method whose only purpose is to prefill a text box. I think that I'd prefer to add an optional reference to the parsed argument options object, to the Environment instance, which could then be used to prefill the text inputs (if it's set).

I also noticed that web_port and web_host are not used in master right now. Should I go ahead and fix this in this PR or should there be a separate one?

Oh, nice catch. A separate PR for that would be great!

locust/main.py Show resolved Hide resolved
@Trouv
Copy link
Contributor Author

Trouv commented Apr 19, 2020

I think that I'd prefer to add an optional reference to the parsed argument options object, to the Environment instance, which could then be used to prefill the text inputs (if it's set).

That's a great idea! I'll get on it

locust/test/test_web.py Outdated Show resolved Hide resolved
@Trouv Trouv mentioned this pull request Apr 20, 2020
@cyberw
Copy link
Collaborator

cyberw commented Apr 21, 2020

I'm +1 to merge. Maybe a mention of this feature somewhere in the documentation would be good though.

@heyman heyman merged commit 768075e into locustio:master Apr 21, 2020
@heyman
Copy link
Member

heyman commented Apr 21, 2020

Merged! Good job!

Maybe a mention of this feature somewhere in the documentation would be good though.

Added an entry to the changelog in 2d0cc67

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

command line arguments for clients and spawn rate should populate ui in the same way as url
3 participants