Telerik Forums
Testing Framework Forum
29 answers
926 views
The pop up window exists with alert dialog with OK and Cancel button.

We have written the below code to handle dialogs:

//Dialog handler code
AlertDialog altDlg = new AlertDialog(ActiveBrowser,DialogButton.OK);

Manager.DialogMonitor.AddDialog(altDlg);

Manager.DialogMonitor.Start();

//The alert dialog opens On click of below button
PfmPageManager.EditQuestionsPage.Elements.SaveTextButton.Click();

When the alert dialog opens and clicks on Ok button the pop up window closes.
Next it tries to execute this code : PfmPageManager.EditQuestionsPage.Elements.SaveTextButton.Click();
and fails here throwing Null pointer exception as this button exists in the pop up window which is already closed.

Please let me know if you have any soltuion for this.

Thanks,
Hemashree





Nikolay Petrov
Telerik team
 answered on 12 Jun 2017
3 answers
320 views

The MouseClick event does not click on the element.  The mouse always clicks in the wrong location.  This is a sample of what my code looks like where cw is my active browser.

cw.Find.ById<HtmlInputText>("igtxtctl00_Main_txtCycleIntervalNum").MouseClick();

This is working in IE but does not click in the correct location in FF or Chrome.  This is only a problem on my machine.  I can execute the same tests on another machines and it clicks in the correct location.  I recently got some new high resolution monitors and was thinking the issue might be with my monitors.  I changed the resolution to the same resolution as the machines the tests work on and they still break on my machine.  At a loss of what to do.

 

Nikolay Petrov
Telerik team
 answered on 09 Jun 2017
6 answers
123 views
I get an error message when trying to use the InvokeScript method in Edge.  It works in all other browsers but Edge.  Am I missing a browser setting somewhere? I can open the development tools in Edge and run the same javascript in the console that I am passing to the InvokeScript method and it works fine.
Nikolay Petrov
Telerik team
 answered on 09 Jun 2017
2 answers
166 views

Hi,

I am running my Test Cases on 3 browsers i.e Internet Explorer, Google Chrome, Mozilla Firefox. But I am facing "QTAgent32.exe has stopped working " only on Firefox and on other browsers it is working fine.

Please find the below attachment for error details. 

Although we have updated our Telerik framework 2016.3 to 2017.2 but still we are facing the same issue again.

We are running our Test Cases on Firefox version : 52.0.1

 

 

 

Elena
Telerik team
 answered on 08 Jun 2017
14 answers
544 views
Hello,

I am automating an application which has majority of the controls build using KendoUI such as e.g. KendoGrid.

Now I test to create, edit and delete entries of my grid. The Problem now is, I can't find a way, to automaticaly set the filter of a column with the testing framework.
I managed to get a reference to my grid by:
KendoGrid grid = myManager.ActiveBrowser.Find.ById<KendoGrid> (gridId);
I also managed, to select a row, but for correct testing I try to filter for my test entries.

How can I achieve this?

I use Kendo 2014.1.318 and testing framework 2014.1.410.0

Greetings
  Thomas
Elena
Telerik team
 answered on 06 Jun 2017
7 answers
578 views

Hi,

can you help me to find solution for my case?

I have attached an example. 

My application has 3 windows - 2 are visible, and one has Visibility = Hidden.

By WpfApplication.Windows.Count i can get 2 visible windows. But after my third window become Visible the count is still 2. 

I can see two ways to pass this problem:

1) refresh WpfApplication, like WpfApplication.MainWindow.RefreshVisualTrees() but for the entire application;

2) initialize WpfApplication after my window will be Visible, i.e. connect through the processID.

The problem is that i was not able to find the way to implement any of this options. 

Can you suggest something?

Elena
Telerik team
 answered on 05 Jun 2017
18 answers
266 views

I have an MVC application in which a view contains a Kendo Grid htmlhelper.  As such, I just specify the columns in the grid, and when the view is loaded it adds the rows and data based on the data source:

@(Html.Kendo().Grid<CustomerJob>()
                            .Name("customerJobGrid")
                            .DataSource(dataSource => dataSource
                                .Ajax()
                                .Sort(sort =>
                                {
                                    sort.Add("IsFavorite").Descending();
                                    sort.Add("JobNo").Descending();
                                })
                                .Read(read => read.Action("Jobs_Active_Read", "DashBoard"))
                                .Model(model => model.Id(p => p.JobNo)
                                )
                            )
                            .Columns(columns =>
                            {
                                columns.Template(p => { }).ClientTemplate(
                            "# if(IsFavorite == 1) { #" +
                                "<span id=\"star-#=NavCustomerNo#-#=JobNo#\" class=\"favorite-star glyphicon glyphicon-star\"></span>" +
                             "# } else { #" +
                                "<span id=\"star-#=NavCustomerNo#-#=JobNo#\" class=\"favorite-star glyphicon glyphicon-star-empty\"></span>" +
                             "# } # "
                            ).Width(50);
                                columns.Bound(p => p.CustomerName).Title("Account");
                                columns.Bound(p => p.Nickname).Title("Name");
                                columns.Bound(p => p.JobNo).Title("Job ID").Width(90).MinScreenWidth(768);
                            })
                            .Pageable()
                            .Sortable()
                            .Scrollable()
                            .Filterable()
                            .Mobile(MobileMode.Disabled)
                            .Selectable(selectable => selectable
                                         .Mode(GridSelectionMode.Single)
                                         .Type(GridSelectionType.Row))
                                        .Events(events => events.Change("onChange"))
                            .HtmlAttributes(new { style = "height:400px;" })
                )

So in the view, I can click within a cell in the grid and it will take me to a page specific for that row.

I would like to automate this using the test framework, so my test can find a cell either by a specified row and column or by a specified text content, and then click in that cell.

I did find this thread, but it's specific to an actual Kendo UI Grid:  http://www.telerik.com/forums/automating-kendo-ui-controls

I need help with this for the htmlhelper version.

Thank you!

Elena
Telerik team
 answered on 29 May 2017
5 answers
233 views
Hey, telerik

is there any translator for kendo UI dropdownlist ? If you do/don't have, could you give sample snippet of codes how to select list item?

Thanks, 
Rick
Top achievements
Rank 1
 answered on 24 May 2017
1 answer
111 views

Using the Find.ByAttributes<T>() method I am able to find a specific control in the DOM, but once found I cannot cast it to a more specific type, HtmlInputText. The control is an input field, which can be seen in the HtmlControl properties. I then attempt to cast the HtmlControl by simply:

HtmlInputText _email = ctrl as HtmlInputText; (ctrl is the generic HtmlControl)

I could work with the HtmlControl, but there are specific methods and properties that the HtmlInputControl has that the more generic HtmlControl does not.

I was hoping to find any feedback on why the casting could not be done, when the HtmlControl returned was an input control.

Elena
Telerik team
 answered on 16 May 2017
1 answer
103 views

How to get a vaule form TextBlock for FontSize.

I need to get number 14 !

 

<TextBlock Grid.Row="1"
                                   TextWrapping="Wrap"
                                   Margin="5"
                                   Name="TextBlockAbout"
                                   FontSize="14">
 </TextBlock>

 

var fSize = TextBlockAbout.GetProperty<TextBlock>("FontSize");

 

Regards,

Peter

Nikolay Petrov
Telerik team
 answered on 15 May 2017
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?