Trim the connecting string and add new tests#3629
Conversation
The original approach does not ignore newline or carriage return, what cause errors that will be described in a GitHub issue.
|
@microsoft-github-policy-service agree |
|
/spotless |
|
@progxaker Thank you for having reported the issue and created a PR to fix it! The PR is marked as draft. Is it ready for review? |
|
Hello @jeanbisutti. If there are no crucial mistakes, then yes, I can open for review. |
|
@progxaker It looks good to me! Could you please run |
|
Done. |
jeanbisutti
left a comment
There was a problem hiding this comment.
Could you please accept these modifications to fix other code format issues?
|
Never mind, just didn't refresh the page. |
Co-authored-by: Jean Bisutti <jean.bisutti@gmail.com>
|
@progxaker I don't think this PR will fix #3628. connection-string.txt should only contain one line for the connection string. |
|
@jeanbisutti, but I didn't say we need to support multi-line. There is the problem that even if I specify a single line (see failed files), App Insights reads |
|
@progxaker I have reproduced the issue. Thank you! |
|
thank you @progxaker! |
Fix #3628. The original approach does not ignore newline or carriage return.
As I mentioned in the issue, I created the following files and reproduced them in the tests:
(Success) No line terminator
(Failed) CRLF line terminator (Windows)
(Failed) CR line terminator (Mac OS)
(Failed) LF line terminator (Linux)
Decisions
trim()function.StandardOpenOptionclass import, I can rewrite that block.Tests
Failed test results
The PR is open as a draft, as I'd like to get your opinion on it and make changes if necessary.
(I'm just not a developer, so I might be missing something).