-
Notifications
You must be signed in to change notification settings - Fork 330
Integration test update #3374
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
Integration test update #3374
Conversation
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.
Looks awesome. A few questions mainly...
inner class InspectorPanelFixture(val inspectorPanel: InspectorPanel) { | ||
// The InspectorPanel is a little tricky to work with. In order for the tree to have content its view must be made | ||
// visible (either Widgets or Render Tree). However, we don't want to return a reference to an empty tree, because | ||
// of timing issues. We use the fact that the tree has content as a signal to move on to the next step. |
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.
These notes are super clarifying. Thanks for the comments! :)
@jacob314: knowing the inspector internals, does this sound like a reasonable approach to you?
|
||
fun selectRow(number: Int, expand: Boolean = true) { | ||
waitForContent() | ||
treeFixture().clickRow(number) // This should not collapse the tree, but it does. |
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.
Is this a fixture bug or in the inspector?
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.
It looks like an off-by-one error. The click occurs exactly on the left-side boundary of the row bounding box. That rectangle apparently overlaps the bounding box of the triangle icon that expands and collapses the sub-tree. I don't think it is a framework error because I can, with sufficient care, reproduce the problem manually. OTOH if the click was in the center of the bounding box there'd be no problem, but that's a choice made by fest, a library used by the testing framework.
|
||
private fun IdeFrameFixture.findActionButtonByActionId(actionId: String): ActionButtonFixture { | ||
private fun findActionButtonByActionId(actionId: String): ActionButtonFixture { | ||
// This seems to be broken, but finding by simple class name works. |
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.
Bummer. But I guess since we own all the classes under test, not a big deal?
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 what the problem is. I haven't even ruled out pilot error (hmm, that may not be a great idiom these days). It might be a bug in the framework. I keep this around to remind myself not to use it.
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.
👍
* Add a test to verify correctness of hot reload
This includes a test for hot reload that uses the inspector to verify it actually worked. Pretty cool, I think :)
I added a bunch of
step
calls that wrap a block and log a message. Generally, if the first line of the diff starts with "step" then the only change is indentation.@pq @jacob314