-
Notifications
You must be signed in to change notification settings - Fork 1.9k
[iOS] Fixed the crash occurred on CarouselView2 when deleting last one remaining item with loop as false #31537
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,74 @@ | ||||||
| using System.Collections.ObjectModel; | ||||||
|
|
||||||
| namespace Maui.Controls.Sample.Issues; | ||||||
|
|
||||||
| [Issue(IssueTracker.Github, 31535, "[iOS] Crash occured on CarouselView2 when deleting last one remaining item with loop as false", PlatformAffected.iOS)] | ||||||
|
||||||
| [Issue(IssueTracker.Github, 31535, "[iOS] Crash occured on CarouselView2 when deleting last one remaining item with loop as false", PlatformAffected.iOS)] | |
| [Issue(IssueTracker.Github, 31535, "[iOS] Crash occurred on CarouselView2 when deleting last one remaining item with loop as false", PlatformAffected.iOS)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
modified
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can include other button to add items?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added the test covering scenarios.
- Started with Empty colleciton
2.Added Single Item
3.Removed single item
4.Added Multiple Items
5.Removed All Items
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,23 @@ | ||||||
| using NUnit.Framework; | ||||||
| using UITest.Appium; | ||||||
| using UITest.Core; | ||||||
|
|
||||||
| namespace Microsoft.Maui.TestCases.Tests.Issues; | ||||||
|
|
||||||
| public class Issue31535 : _IssuesUITest | ||||||
| { | ||||||
| public Issue31535(TestDevice device) : base(device) { } | ||||||
|
|
||||||
| public override string Issue => "[iOS] Crash occured on CarouselView2 when deleting last one remaining item with loop as false"; | ||||||
|
||||||
| public override string Issue => "[iOS] Crash occured on CarouselView2 when deleting last one remaining item with loop as false"; | |
| public override string Issue => "[iOS] Crash occurred on CarouselView2 when deleting last one remaining item with loop as false"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
modified
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could include another test, similar but removing more than one time the last item?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The current test already performs the remove action twice, so it seems you might be referring to the same scenario. Could you please confirm if this is sufficient, or would you prefer that we add more items and invoke the remove function multiple times? @jsuarezruiz
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Something like:
- Start with empty collection
- Add single item - should not crash
- Add multiple items - should work correctly
- Remove all items - should handle gracefully
Uh oh!
There was an error while loading. Please reload this page.