How to select referenced dropdown in angularjs using selenium python

  angular, python, selenium

I am trying to access the elements in the dropdown. Unlike other drop downs that have the options and values written in one place. Like this:

<select>
 <option value="volvo">Volvo</option>
 <option value="saab">Saab</option>
 <option value="mercedes">Mercedes</option>
 <option value="audi">Audi</option>
 </select>

This dropdown has it’s elements or attributes referenced to another file.

<div class="row">

  <div class="col-xs-4 col-sm-4 col-md-4 col-lg-4">

    <div class="chk-block" style="padding: 25px;">


      <mat-form-field class="mat">
        <mat-select id="drp1" placeholder="Select Term" [(ngModel)]="selectedTerm" #term>
          <mat-option [value]="schoolTerm.Term_Name" *ngFor="let schoolTerm of schoolTerms" (click)="setTheTerm($event,i,schoolTerm)">
            {{ schoolTerm.Term_Name }}
          </mat-option>
        </mat-select>
      </mat-form-field>

Source: Angular Questions

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.