私はXamarinを使用してVisual Studio 2013のcross-platform
アプリケーションの自動化に取り組んでいます。そして、私は現在、ページ上のテキストフィールドから値を読み取るのに苦労しています。これを行うために使用できる方法はありますか?要素のXamarin UIテストのテキストフィールドから値を読み取るREPL
例REPL
から属性:
Id => "app_url",
Label => "ApplicationUrlEntryField",
Text => "https://myurladdress.com",
Class => "android.widget.AutoCompleteTextView",
Enabled => true
今、私は=>https://myurladdress.com
おかげでテキスト値を必要としています。
[EDIT]
実際にそれを解決:
app.Query(x => x.Marked("ApplicationUrlEntryField").Invoke("getText"));
- そのID
あなたはREPLを起動した後、あなたは[ 'tree'コマンド](https://developer.xamarin.com/guides/testcloud/uitest/working-with/repl/#Discovering_Views_With_the_tree_Command)を実行することができます。これにより、画面に表示されるビューのリストとその 'text'プロパティが表示されます。 – Demitrian