Commit 6066a7e
committed
Use {argName} for validating deep link arguments
While in many cases query parameters are in the
form of myarg={myarg}, this should never be a hard
requirement. Instead, only the value within braces
(what is actually used as the argument name) should
be used when validating that all required
arguments are present in the NavDeepLink.
Relnote: "Fixed a regression introduced in
[Navigation `2.4.0-alpha09`](#2.4.0-alpha09) when using
deep links with query parameters where Navigation would
incorrectly validate argument names using the query
parameter name (i.e., the `id` of `?id={userId}`) rather
than using the actual argument names present in the value
(the `userId` in the example above)."
Test: new NavDestinationAndroidTest tests pass
BUG: 200845660
Change-Id: Id2f399a5e19e593f34e02fc811f1cc28ec0689b81 parent ddc7cd2 commit 6066a7e
2 files changed
Lines changed: 40 additions & 2 deletions
File tree
navigation/navigation-common/src/androidTest/java/androidx/navigation/NavDestinationAndroidTest.kt
Lines changed: 38 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
114 | 152 | | |
115 | 153 | | |
116 | 154 | | |
| |||
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | | - | |
| 59 | + | |
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
| |||
234 | 234 | | |
235 | 235 | | |
236 | 236 | | |
237 | | - | |
| 237 | + | |
238 | 238 | | |
239 | 239 | | |
240 | 240 | | |
| |||
0 commit comments