|
15 | 15 | package queries |
16 | 16 |
|
17 | 17 | import ( |
18 | | - "github.com/dolthub/vitess/go/mysql" |
19 | 18 | "math" |
20 | 19 | "time" |
21 | 20 |
|
| 21 | + "github.com/dolthub/vitess/go/mysql" |
22 | 22 | "github.com/dolthub/vitess/go/sqltypes" |
23 | 23 | "github.com/dolthub/vitess/go/vt/sqlparser" |
24 | 24 | "gopkg.in/src-d/go-errors.v1" |
@@ -154,74 +154,74 @@ var ScriptTests = []ScriptTest{ |
154 | 154 | }, |
155 | 155 | { |
156 | 156 | // https://github.com/dolthub/dolt/issues/9812 |
157 | | - Name: "String-to-number comparison operators should behave consistently", |
| 157 | + Name: "String-to-number comparison operators should behave consistently", |
158 | 158 | Assertions: []ScriptTestAssertion{ |
159 | 159 | { |
160 | | - Dialect: "mysql", |
| 160 | + Dialect: "mysql", |
161 | 161 | Query: "SELECT ('A') = (0)", |
162 | 162 | Expected: []sql.Row{{true}}, |
163 | 163 | //ExpectedWarningsCount: 1, |
164 | 164 | //ExpectedWarning: mysql.ERTruncatedWrongValue, |
165 | 165 | //ExpectedWarningMessageSubstring: "Truncated incorrect double value: A", |
166 | 166 | }, |
167 | 167 | { |
168 | | - Dialect: "mysql", |
| 168 | + Dialect: "mysql", |
169 | 169 | Query: "SELECT ('A') IN (0)", |
170 | 170 | Expected: []sql.Row{{true}}, |
171 | 171 | //ExpectedWarningsCount: 1, |
172 | 172 | //ExpectedWarning: mysql.ERTruncatedWrongValue, |
173 | 173 | //ExpectedWarningMessageSubstring: "Truncated incorrect double value: A", |
174 | 174 | }, |
175 | 175 | { |
176 | | - Dialect: "mysql", |
| 176 | + Dialect: "mysql", |
177 | 177 | Query: "SELECT ('A') != (0)", |
178 | 178 | Expected: []sql.Row{{false}}, |
179 | 179 | //ExpectedWarningsCount: 1, |
180 | 180 | //ExpectedWarning: mysql.ERTruncatedWrongValue, |
181 | 181 | //ExpectedWarningMessageSubstring: "Truncated incorrect double value: A", |
182 | 182 | }, |
183 | 183 | { |
184 | | - Dialect: "mysql", |
| 184 | + Dialect: "mysql", |
185 | 185 | Query: "SELECT ('A') <> (0)", |
186 | 186 | Expected: []sql.Row{{false}}, |
187 | 187 | //ExpectedWarningsCount: 1, |
188 | 188 | //ExpectedWarning: mysql.ERTruncatedWrongValue, |
189 | 189 | //ExpectedWarningMessageSubstring: "Truncated incorrect double value: A", |
190 | 190 | }, |
191 | 191 | { |
192 | | - Dialect: "mysql", |
| 192 | + Dialect: "mysql", |
193 | 193 | Query: "SELECT ('A') < (0)", |
194 | 194 | Expected: []sql.Row{{false}}, |
195 | 195 | //ExpectedWarningsCount: 1, |
196 | 196 | //ExpectedWarning: mysql.ERTruncatedWrongValue, |
197 | 197 | //ExpectedWarningMessageSubstring: "Truncated incorrect double value: A", |
198 | 198 | }, |
199 | 199 | { |
200 | | - Dialect: "mysql", |
| 200 | + Dialect: "mysql", |
201 | 201 | Query: "SELECT ('A') <= (0)", |
202 | 202 | Expected: []sql.Row{{true}}, |
203 | 203 | //ExpectedWarningsCount: 1, |
204 | 204 | //ExpectedWarning: mysql.ERTruncatedWrongValue, |
205 | 205 | //ExpectedWarningMessageSubstring: "Truncated incorrect double value: A", |
206 | 206 | }, |
207 | 207 | { |
208 | | - Dialect: "mysql", |
| 208 | + Dialect: "mysql", |
209 | 209 | Query: "SELECT ('A') > (0)", |
210 | 210 | Expected: []sql.Row{{false}}, |
211 | 211 | //ExpectedWarningsCount: 1, |
212 | 212 | //ExpectedWarning: mysql.ERTruncatedWrongValue, |
213 | 213 | //ExpectedWarningMessageSubstring: "Truncated incorrect double value: A", |
214 | 214 | }, |
215 | 215 | { |
216 | | - Dialect: "mysql", |
| 216 | + Dialect: "mysql", |
217 | 217 | Query: "SELECT ('A') >= (0)", |
218 | 218 | Expected: []sql.Row{{true}}, |
219 | 219 | //ExpectedWarningsCount: 1, |
220 | 220 | //ExpectedWarning: mysql.ERTruncatedWrongValue, |
221 | 221 | //ExpectedWarningMessageSubstring: "Truncated incorrect double value: A", |
222 | 222 | }, |
223 | 223 | { |
224 | | - Dialect: "mysql", |
| 224 | + Dialect: "mysql", |
225 | 225 | Query: "SELECT ('A') NOT IN (0)", |
226 | 226 | Expected: []sql.Row{{false}}, |
227 | 227 | //ExpectedWarningsCount: 1, |
|
0 commit comments