Results 1 to 3 of 3

Thread: Treelistitem without subnodes is not clicked

  1. #1

    Default Treelistitem without subnodes is not clicked

    Hi,
    i am having struggles with clicking "DPP" as on the attached file. On cliking DPP i would expect a differnt view to appear on the right side of the screen, but it does not. To confirm if it works, i then tried with another item from the treelist "PIM" and it expanded the menu so that i could see subnodes. That led me to the assumption that there are issues with clicking a treelistitem without subnodes.

    Here my code:

    Code:
    it("Should click DPP", function () {
            ST.component('treelistitem[text="DPP"]')
            .click(10, 10)
    });
    when exchanging DPP for PIM it clicks on the PIM entry without problems. The locators were found using the "Sencha component locator". I spent so much time trying to click DPP to have my view change. Help would be very much appreciated.

    Best regards
    Michael
    Attached Images Attached Images

  2. #2
    Sencha User
    Join Date
    Mar 2017
    Posts
    50

    Default

    Try adding a .wait(1000) after clicking the treelistitem to see if the right pane populates. Currently you're just asking ST to click which may be happening but it's not very obvious. You can also pick a component from the right pane and confirm that it's visible using the .visible() & .wait(1000) to see if something is actually populating.

    I've included one of my helper functions used throughout my suite to expand tree lists. You May be able to modify it to suite your needs.

    expandAllForTree: function(treeLocator) {
    treeLocator().execute(function(grid) {
    var rootNode = grid.getStore().getRoot();
    rootNode.expand();
    rootNode.expandChildren(true).wait(1500);
    });
    },

  3. #3

    Default

    Hi Swillo,

    thanks so much for trying to help me. For some reason i tried to use an "beforall" function to always wait because i am quite new to this and want to see whats happening the wait of course makes sense. Today i found out that somehow my first function for clicking a "treelistitem" is being ignored. The second function for clicking a treelistitem actually works then. I created a bug in the Sencha support. Mabye there is something wrong.

    Thanks for the expandallfortree function. It might come in handy one day.

    Have a great day and 1000 thanks

    Michael

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •