-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
💲[Native Checkout] "Peek" functionality using hidden scroll view (#665)
* New files * removing scroll view stuff for now * Tests * Cleaning up insets * More cleanup * Swiftlint * Adding “deprecated” to more file names * Removing duplicated file * Increasing hit area of close button * Hidden scroll view * Hidden scroll view working * Refactoring & cleanup * Use collection view’s content size * PR updates from comments * Fix autolayout warnings on device rotation * Cleanup * More cleanup * More PR feedback
- Loading branch information
Showing
4 changed files
with
156 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import XCTest | ||
@testable import Library | ||
|
||
final class UIViewAutoLayoutExtensionTests: TestCase { | ||
func test_insertSubviewInParentAtIndex_oneSubview() { | ||
let view1 = UIView(frame: .zero) | ||
let view2 = UIView(frame: .zero) | ||
|
||
_ = (view2, view1) | ||
|
||
_ = ksr_insertSubviewInParent(at: 0)(view2, view1) | ||
|
||
XCTAssertEqual(view1.subviews.count, 1) | ||
XCTAssertEqual(view1.subviews[0], view2) | ||
} | ||
} |