@@ -81,11 +81,24 @@ Item {
83 function test_send_review() {
83 function test_send_review() {
84+ sendReviewSpy.clear();
84 var sendButton = findChild(appReviews, "sendButton");
85 var sendButton = findChild(appReviews, "sendButton");
85− mouseClick(sendButton, 1, 1)
86+ mouseClick(sendButton, 1, 1);
86 compare(sendReviewSpy.count, 1, "SendReview signal not emitted");
87 compare(sendReviewSpy.count, 1, "SendReview signal not emitted");
90+ function test_review_focus() {
91+ sendReviewSpy.clear();
92+ var sendButton = findChild(appReviews, "sendButton");
93+ var reviewField = findChild(appReviews, "reviewField");
95+ compare(reviewField.focus, false);
96+ compare(appReviews.state, "");
97+ mouseClick(reviewField, 1, 1);
98+ compare(reviewField.focus, true);
99+ compare(appReviews.state, "editing");
89 function test_comments() {
102 function test_comments() {
90 var commentsArea = findChild(appReviews, "commentsArea");
103 var commentsArea = findChild(appReviews, "commentsArea");
91 compare(commentsArea.count, 4);
104 compare(commentsArea.count, 4);