How can I select the dropdown button with by locate the ng-repeat?How to select option in drop down protractorjs e2e testsHow can I select an element in a component template?How can I get new selection in “select” in Angular 2?How can I close a dropdown on click outside?How to locate and click an ng-click button in a repeaterSelect option from dropdown in app non-angularselect the locator for passing valuesLocate a button by css and buttonTexthow to write a locator and select a dropdown valueNot able to locate and select the dropdown value in AngularJs using Protractor

What's this constructed number's starter?

How many people can lift Thor's hammer?

What's the difference between a share and a stock?

A Meal fit for a King

Is Sanskrit really the mother of all languages?

Are there mathematical concepts that exist in the fourth dimension, but not in the third dimension?

Would you recommend a keyboard for beginners with or without lights in keys for learning?

If I have an accident, should I file a claim with my car insurance company?

Why does the seven segment display have decimal point at the right?

Why do old games use flashing as means of showing damage?

Why don't they build airplanes from 3D printer plastic?

Do we know what "hardness" of Brexit people actually wanted in the referendum, if there had been other choices available?

Default argument for a functor in a templated parameter

Numerical minimum of a one-valued function

Professor refuses to write a recommendation letter to students who haven't written a research paper with him

Why is a pressure canner needed when canning?

How does the UK House of Commons think they can prolong the deadline of Brexit?

What are some countries where you can be imprisoned for reading or owning a Bible?

FORMAT returns large row size and data size

Is directly echoing the user agent in PHP a security hole?

Low quality postdoc application and deadline extension

Do I have to rename all creatures in a new world?

Bidirectional Dictionary

Project Euler Problem 45



How can I select the dropdown button with by locate the ng-repeat?


How to select option in drop down protractorjs e2e testsHow can I select an element in a component template?How can I get new selection in “select” in Angular 2?How can I close a dropdown on click outside?How to locate and click an ng-click button in a repeaterSelect option from dropdown in app non-angularselect the locator for passing valuesLocate a button by css and buttonTexthow to write a locator and select a dropdown valueNot able to locate and select the dropdown value in AngularJs using Protractor






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








0















I want to do an automation test case to create a subnet. However, I could not select the classes that I want in the dropdown list.



Below is the code that I try to use.



async setSubnetClass(classes: String) {
let val: ElementFinder;

switch (classes) {
case "/8":
val = element(by.repeater('prefix in prefixes').row(0));
// val = this.VolumeType.row(0); tryyyyyyyyyyyy
break;
case "/9":
val = element(by.repeater('prefix in prefixes').row(1));
// val = this.VolumeType.row(1);
break;
case "/10":
val = element(by.repeater('prefix in prefixes').row(2));
// val = this.VolumeType.row(1);
break;


and then this is the html result of the table html file



<button data-toggle="dropdown" class="btn btn-default dropdown-toggle">
<span>/&nbsp;selectedPrefix.id&nbsp;</span>
<span style='font-size:10px;'>
(selectedPrefix.usableips IPs)</span> <span class="caret"></span>
</button>


Please teach me and give some hint on how to fix it?










share|improve this question
































    0















    I want to do an automation test case to create a subnet. However, I could not select the classes that I want in the dropdown list.



    Below is the code that I try to use.



    async setSubnetClass(classes: String) {
    let val: ElementFinder;

    switch (classes) {
    case "/8":
    val = element(by.repeater('prefix in prefixes').row(0));
    // val = this.VolumeType.row(0); tryyyyyyyyyyyy
    break;
    case "/9":
    val = element(by.repeater('prefix in prefixes').row(1));
    // val = this.VolumeType.row(1);
    break;
    case "/10":
    val = element(by.repeater('prefix in prefixes').row(2));
    // val = this.VolumeType.row(1);
    break;


    and then this is the html result of the table html file



    <button data-toggle="dropdown" class="btn btn-default dropdown-toggle">
    <span>/&nbsp;selectedPrefix.id&nbsp;</span>
    <span style='font-size:10px;'>
    (selectedPrefix.usableips IPs)</span> <span class="caret"></span>
    </button>


    Please teach me and give some hint on how to fix it?










    share|improve this question




























      0












      0








      0








      I want to do an automation test case to create a subnet. However, I could not select the classes that I want in the dropdown list.



      Below is the code that I try to use.



      async setSubnetClass(classes: String) {
      let val: ElementFinder;

      switch (classes) {
      case "/8":
      val = element(by.repeater('prefix in prefixes').row(0));
      // val = this.VolumeType.row(0); tryyyyyyyyyyyy
      break;
      case "/9":
      val = element(by.repeater('prefix in prefixes').row(1));
      // val = this.VolumeType.row(1);
      break;
      case "/10":
      val = element(by.repeater('prefix in prefixes').row(2));
      // val = this.VolumeType.row(1);
      break;


      and then this is the html result of the table html file



      <button data-toggle="dropdown" class="btn btn-default dropdown-toggle">
      <span>/&nbsp;selectedPrefix.id&nbsp;</span>
      <span style='font-size:10px;'>
      (selectedPrefix.usableips IPs)</span> <span class="caret"></span>
      </button>


      Please teach me and give some hint on how to fix it?










      share|improve this question
















      I want to do an automation test case to create a subnet. However, I could not select the classes that I want in the dropdown list.



      Below is the code that I try to use.



      async setSubnetClass(classes: String) {
      let val: ElementFinder;

      switch (classes) {
      case "/8":
      val = element(by.repeater('prefix in prefixes').row(0));
      // val = this.VolumeType.row(0); tryyyyyyyyyyyy
      break;
      case "/9":
      val = element(by.repeater('prefix in prefixes').row(1));
      // val = this.VolumeType.row(1);
      break;
      case "/10":
      val = element(by.repeater('prefix in prefixes').row(2));
      // val = this.VolumeType.row(1);
      break;


      and then this is the html result of the table html file



      <button data-toggle="dropdown" class="btn btn-default dropdown-toggle">
      <span>/&nbsp;selectedPrefix.id&nbsp;</span>
      <span style='font-size:10px;'>
      (selectedPrefix.usableips IPs)</span> <span class="caret"></span>
      </button>


      Please teach me and give some hint on how to fix it?







      angular selenium protractor






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 28 at 4:19









      Amir

      83910 silver badges25 bronze badges




      83910 silver badges25 bronze badges










      asked Mar 28 at 4:08









      BING HAO LIMBING HAO LIM

      11 bronze badge




      11 bronze badge

























          1 Answer
          1






          active

          oldest

          votes


















          0
















          Try the below one



          async setSubnetClass(classes: String) // pass classes = '/8' to select.

          const drop = element(by.css('ul>li>a'));
          await drop.sendKeys(classes);



          So the above method selects /8 from your drop down.



          Hope it help you






          share|improve this answer

























          • I try use the code you provide, but when I run the test, it skip to click drop down, straight jump to next step. what is the problem there?

            – BING HAO LIM
            Mar 28 at 7:20











          • @BINGHAOLIM Can you share the particular html and your test script so that we can resolve the same.

            – Madhan
            Mar 28 at 7:22











          • yeah sure. gv me couple of time, i tried to update on the top

            – BING HAO LIM
            Mar 28 at 8:56










          Your Answer






          StackExchange.ifUsing("editor", function ()
          StackExchange.using("externalEditor", function ()
          StackExchange.using("snippets", function ()
          StackExchange.snippets.init();
          );
          );
          , "code-snippets");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "1"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55390013%2fhow-can-i-select-the-dropdown-button-with-by-locate-the-ng-repeat%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          0
















          Try the below one



          async setSubnetClass(classes: String) // pass classes = '/8' to select.

          const drop = element(by.css('ul>li>a'));
          await drop.sendKeys(classes);



          So the above method selects /8 from your drop down.



          Hope it help you






          share|improve this answer

























          • I try use the code you provide, but when I run the test, it skip to click drop down, straight jump to next step. what is the problem there?

            – BING HAO LIM
            Mar 28 at 7:20











          • @BINGHAOLIM Can you share the particular html and your test script so that we can resolve the same.

            – Madhan
            Mar 28 at 7:22











          • yeah sure. gv me couple of time, i tried to update on the top

            – BING HAO LIM
            Mar 28 at 8:56















          0
















          Try the below one



          async setSubnetClass(classes: String) // pass classes = '/8' to select.

          const drop = element(by.css('ul>li>a'));
          await drop.sendKeys(classes);



          So the above method selects /8 from your drop down.



          Hope it help you






          share|improve this answer

























          • I try use the code you provide, but when I run the test, it skip to click drop down, straight jump to next step. what is the problem there?

            – BING HAO LIM
            Mar 28 at 7:20











          • @BINGHAOLIM Can you share the particular html and your test script so that we can resolve the same.

            – Madhan
            Mar 28 at 7:22











          • yeah sure. gv me couple of time, i tried to update on the top

            – BING HAO LIM
            Mar 28 at 8:56













          0














          0










          0









          Try the below one



          async setSubnetClass(classes: String) // pass classes = '/8' to select.

          const drop = element(by.css('ul>li>a'));
          await drop.sendKeys(classes);



          So the above method selects /8 from your drop down.



          Hope it help you






          share|improve this answer













          Try the below one



          async setSubnetClass(classes: String) // pass classes = '/8' to select.

          const drop = element(by.css('ul>li>a'));
          await drop.sendKeys(classes);



          So the above method selects /8 from your drop down.



          Hope it help you







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Mar 28 at 5:12









          MadhanMadhan

          9101 gold badge2 silver badges11 bronze badges




          9101 gold badge2 silver badges11 bronze badges















          • I try use the code you provide, but when I run the test, it skip to click drop down, straight jump to next step. what is the problem there?

            – BING HAO LIM
            Mar 28 at 7:20











          • @BINGHAOLIM Can you share the particular html and your test script so that we can resolve the same.

            – Madhan
            Mar 28 at 7:22











          • yeah sure. gv me couple of time, i tried to update on the top

            – BING HAO LIM
            Mar 28 at 8:56

















          • I try use the code you provide, but when I run the test, it skip to click drop down, straight jump to next step. what is the problem there?

            – BING HAO LIM
            Mar 28 at 7:20











          • @BINGHAOLIM Can you share the particular html and your test script so that we can resolve the same.

            – Madhan
            Mar 28 at 7:22











          • yeah sure. gv me couple of time, i tried to update on the top

            – BING HAO LIM
            Mar 28 at 8:56
















          I try use the code you provide, but when I run the test, it skip to click drop down, straight jump to next step. what is the problem there?

          – BING HAO LIM
          Mar 28 at 7:20





          I try use the code you provide, but when I run the test, it skip to click drop down, straight jump to next step. what is the problem there?

          – BING HAO LIM
          Mar 28 at 7:20













          @BINGHAOLIM Can you share the particular html and your test script so that we can resolve the same.

          – Madhan
          Mar 28 at 7:22





          @BINGHAOLIM Can you share the particular html and your test script so that we can resolve the same.

          – Madhan
          Mar 28 at 7:22













          yeah sure. gv me couple of time, i tried to update on the top

          – BING HAO LIM
          Mar 28 at 8:56





          yeah sure. gv me couple of time, i tried to update on the top

          – BING HAO LIM
          Mar 28 at 8:56








          Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.







          Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.



















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55390013%2fhow-can-i-select-the-dropdown-button-with-by-locate-the-ng-repeat%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

          SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

          은진 송씨 목차 역사 본관 분파 인물 조선 왕실과의 인척 관계 집성촌 항렬자 인구 같이 보기 각주 둘러보기 메뉴은진 송씨세종실록 149권, 지리지 충청도 공주목 은진현