Commit 434cfd6
committed
[tests] Add dictionary sorting to request's parameters
* There is a need to compare two User Update Requests, with limitations of comparing Objc dictionaries to Swift dictionaries, and the Mock Client not knowing about product-specific OneSignalRequest implementations like OSRequestUpdateUser.
* So, we can do comparison via their parameters payload.
* Add logic to stringify the params in alphabetical order to allow streamlined comparison1 parent 3b47509 commit 434cfd6
File tree
4 files changed
+60
-5
lines changed- iOS_SDK/OneSignalSDK
- OneSignal.xcodeproj
- OneSignalCoreMocks
- Extensions
4 files changed
+60
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
155 | 155 | | |
156 | 156 | | |
157 | 157 | | |
| 158 | + | |
158 | 159 | | |
159 | 160 | | |
160 | 161 | | |
| |||
1189 | 1190 | | |
1190 | 1191 | | |
1191 | 1192 | | |
| 1193 | + | |
1192 | 1194 | | |
1193 | 1195 | | |
1194 | 1196 | | |
| |||
1912 | 1914 | | |
1913 | 1915 | | |
1914 | 1916 | | |
| 1917 | + | |
1915 | 1918 | | |
1916 | 1919 | | |
1917 | 1920 | | |
| |||
3760 | 3763 | | |
3761 | 3764 | | |
3762 | 3765 | | |
| 3766 | + | |
3763 | 3767 | | |
3764 | 3768 | | |
3765 | 3769 | | |
| |||
Lines changed: 24 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
73 | 97 | | |
Lines changed: 11 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
Lines changed: 21 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
104 | 119 | | |
105 | 120 | | |
106 | 121 | | |
| |||
110 | 125 | | |
111 | 126 | | |
112 | 127 | | |
| 128 | + | |
113 | 129 | | |
114 | 130 | | |
115 | 131 | | |
116 | 132 | | |
117 | 133 | | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
122 | 138 | | |
123 | 139 | | |
124 | | - | |
| 140 | + | |
125 | 141 | | |
126 | 142 | | |
127 | 143 | | |
| |||
0 commit comments