-
Notifications
You must be signed in to change notification settings - Fork 6.8k
feat(material-experimental): add test harness for input #16674
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
Conversation
436e5b0 to
8f035ed
Compare
|
It looks like there is one failing test on iOS because the Marking as blocked in the meanwhile. This PR can be still reviewed. |
8f035ed to
c8bf616
Compare
This comment has been minimized.
This comment has been minimized.
60e36b0 to
82e0f14
Compare
jelbourn
left a comment
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.
LGTM
82e0f14 to
ce6e2ca
Compare
|
Addressed feedback. PR is currently still blocked on #16706 |
mmalerba
left a comment
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.
This looks good for now, but it'll be interesting to see how it plays with the form-field harness once we create that
| async setValue(newValue: string): Promise<void> { | ||
| const inputEl = await this.host(); | ||
| await inputEl.clear(); | ||
| // We don't want to send keys for the value if the value is an empty |
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.
should we update sendKeys to not do that?
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'm not sure. I could see sendKeys being a noop in that case. Though it also feels like an anti-pattern in general to call sendKeys with an empty value.
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.
Yeah, calling it with empty string is weird and people shouldn't do it, so I'm fine with changing it or just leaving it how it is
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'd vote for leaving it as is, but maybe throwing an error in sendKeys instead? (follow-up)?
|
A Googler has manually verified that the CLAs look good. (Googler, please make sure the reason for overriding the CLA status is clearly documented in these comments.) ℹ️ Googlers: Go here for more info. |
|
This should be unblocked now that |
ce6e2ca to
fd5a2ac
Compare
|
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
|
@mmalerba Rebased. can you have another look? |
mmalerba
left a comment
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.
LGTM with a few nits
src/material-experimental/mdc-input/harness/input-harness.spec.ts
Outdated
Show resolved
Hide resolved
src/material-experimental/mdc-input/harness/input-harness.spec.ts
Outdated
Show resolved
Hide resolved
src/material-experimental/mdc-input/harness/input-harness.spec.ts
Outdated
Show resolved
Hide resolved
src/material-experimental/mdc-input/harness/input-harness.spec.ts
Outdated
Show resolved
Hide resolved
fd5a2ac to
d5a75e2
Compare
Adds a test harness for the `MatInput` implementation. Resolves COMP-182
d5a75e2 to
5abda4a
Compare
jelbourn
left a comment
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.
LGTM
Adds a test harness for the `MatInput` implementation. Resolves COMP-182
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |

Blocked on #16706 and #16645