-
Notifications
You must be signed in to change notification settings - Fork 234
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
Implement filling Webforms in HTTP/HTTPS plugin #95
base: master
Are you sure you want to change the base?
Conversation
2dbc83c
to
949c3f0
Compare
949c3f0
to
723838b
Compare
Please add missing unit tests, fix WebProtocols_CreateControls_ReturnsEmpty test. |
Considering i don't know how to run the tests, i hope this is what you're looking for :) |
Still two tests are failing. I am going to have a look my self. So we can merge it. |
To fix the tests:
|
@@ -6,6 +6,8 @@ public class KnownConnectionConstants | |||
|
|||
public const int HTTPPort = 80; | |||
|
|||
public const int HTTPSPort = 443; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There should be no reason why to move it here, until there is another usage than tests. Leave it in https plugin.
@@ -37,12 +41,17 @@ public ProtocolOptions CreateOptions() | |||
|
|||
public Image GetIcon() | |||
{ | |||
return HttpConnectionPlugin.TreeIconHttp; | |||
return TreeIconHttps; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is the icon moved to this plugin and not referencing the original icon. It looks like a bug?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
internal static readonly Image TreeIconHttps = Resources.treeIcon_http; I added this to "sync" the two plugins to be as equal as possible, could absolutely be reverted :)
public string OptionalID { get; set; } | ||
public string OptionalValue { get; set; } | ||
public string SubmitID { get; set; } | ||
public bool EnableHTMLAuth { get; set; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is the EnableHtmlAuth separated from EnableFormsAuth, what is the difference. I would expect one dropdown to select authentication method. Or is the purpose as fallback authentication?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added both to be able to keep both enabled by default, to ease for users (Not having to chose by default).
{ | ||
UrlConverter.UpdateFavoriteUrl(context.Favorite, context.ConfigFavorite.Url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are this property conversions removed? The property is still there, so it needs to be converted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll look into it :)
|
||
internal class TerminalsWebExport | ||
{ | ||
public static void ExportOptions(ref IExportOptionsContext context) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are you calling the context using ref?
} | ||
} | ||
|
||
internal class TerminalsHTTPSExport : ITerminalsOptionsExport |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to have two exporters, if they do the same. We may implement one for both protocols. See ConnectionManager.IsProtocolWebBased.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correcting this :)
Updated to try and fit your comments. It might still not be perfect for your style though. We'll see :) |
Please add missing tests to cover what is not automatically tested. Otherwise i will fix the issues you dint comment. |
If there's anything you want fixed, feel free to push to my branch too, you should have write access to the pullrequested branches :) My reasoning behind instancing the icon twice and moving the https port definition is only to keep consistency within the codebase. Hope to see this if not merged, implemented :) It's a killer feature! :) |
If you want, we can rebase this branch on master and rewrite the history too :) Contributed to a project awhile ago where a pretty gitlog was important. |
How are we doing on this? I'm not sure which changes i've missed, please rereview this. |
Go through all comments for each file, mainly:
|
@jirkapok It's the wrong way around, but i'd love it if you helped me cleanup the last bits as you'd like them. I think by GitHub design you've got write access to the pullrequest branch. The tests i think i implemented, i'm not sure what's missing. And upgrades i know not how to do. Best Regards |
Based on project resurection, i will cherry pick these changes and implement them in 46-putty branch. |
I'm glad to hear, I don't have any Windows machines anymore so I can't assist, but I suspekt you've got this 😄 |
Support for filling forms in HTTP and HTTPS plugins