Bug 60429 - List items do not appear in appium output for list items when the items are added later (iOS only)
Summary: List items do not appear in appium output for list items when the items are a...
Status: RESOLVED NORESPONSE
Alias: None
Product: Forms
Classification: Xamarin
Component: Forms ()
Version: unspecified
Hardware: PC Windows
: --- major
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2017-10-30 01:11 UTC by nathan.huesken
Modified: 2017-12-04 16:21 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED NORESPONSE

Description nathan.huesken 2017-10-30 01:11:16 UTC
# Steps to reproduce
There is a test-project here: https://github.com/RudolfVonKrugstein/XamarinAutomationIdTest

1. Create a ListView and bind the ItemsSource to a empty ObervableCollection. Also have a DataTemplate that includes a AutomationId. Like this:
```
<ListView ItemsSource="{Binding ItemsSource}">
        <ListView.ItemTemplate>
            <DataTemplate>
                <ViewCell>
                    <Label Text="Hello" AutomationId="Automate"/>
                </ViewCell>
            </DataTemplate>
        </ListView.ItemTemplate>
    </ListView>
```
2. At a later point in the code (after the list has already been displayed) add items to the ListView.
3. Run the project on iOS.
4. Use appium Inspector to inspect the page. Note that the list items arent present in the appium output.

# Expected behavior

The list items should show up in appium inspector as something like this:

```
<XCUIElementTypeTable>
    <XCUIElementTypeCell>
        <XCUIElementTypeStaticText name="Automate">
```

# Actual behavior

The XCUIELementTypeTable shows up as an empty table in the appium inspector output.

# Supplemental info (logs, images, videos)

The problem occurs with xamarin forms 2.4.0.18342, but not with 2.3.4.270.

# Test environment (full version information)

There is a test-project here: https://github.com/RudolfVonKrugstein/XamarinAutomationIdTest
Comment 1 Paul DiPietro [MSFT] 2017-11-09 16:49:29 UTC
Have you raised an issue on the Appium end to get any feedback?
Comment 2 Paul DiPietro [MSFT] 2017-12-04 16:21:43 UTC
Closing due to a lack of response, and at a glance this does not appear to necessarily be a Forms specific issue. Please reopen with a reproduction project if there is a particularly clear bug in Forms.

Guidelines for creating reproductions are available at:
https://github.com/xamarin/Xamarin.Forms/wiki/Submitting-Bug-Reports