Skip to content

Commit 2a78c9f

Browse files
committed
whitespace
1 parent 0206858 commit 2a78c9f

File tree

1 file changed

+13
-14
lines changed

1 file changed

+13
-14
lines changed

test/23.statement.iterate.js

+13-14
Original file line numberDiff line numberDiff line change
@@ -246,19 +246,18 @@ describe('Statement#iterate()', function () {
246246
this.db.prepare(SQL1).iterate('foo', 1, new (function(){})(), Buffer.alloc(4).fill(0xdd), null)
247247
).to.throw(TypeError);
248248
});
249-
250249
it("should read and write non-trivial numbers of rows", function () {
251250
const insertRuntime = 1000
252251
this.timeout(insertRuntime * 2.5);
253252
const runUntil = Date.now() + insertRuntime
254-
let i = 0;
253+
let i = 0;
255254
const r = .141592654
256-
this.db.prepare('CREATE TABLE t (id INTEGER, b TEXT, c REAL)').run();
255+
this.db.prepare('CREATE TABLE t (id INTEGER, b TEXT, c REAL)').run();
257256
const stmt = this.db.prepare("INSERT INTO t VALUES (?, ?, ?)");
258-
while(Date.now() < runUntil) {
257+
while (Date.now() < runUntil) {
259258
// Batched transactions of 100 inserts:
260259
this.db.transaction(() => {
261-
for(const start = i; i < start + 100 ; i++) {
260+
for (const start = i; i < start + 100; i++) {
262261
expect(stmt.run([i, String(i), i + r])).to.deep.equal({
263262
changes: 1,
264263
lastInsertRowid: i + 1
@@ -267,15 +266,15 @@ describe('Statement#iterate()', function () {
267266
})();
268267
}
269268
expect(i).to.be.gte(1000); // < expect ~50K and 200K on reasonable machines
270-
const stmt1 = this.db.prepare("SELECT * FROM t ORDER BY id DESC");
271-
for (const data of stmt1.iterate()) {
269+
const stmt1 = this.db.prepare("SELECT * FROM t ORDER BY id DESC");
270+
for (const data of stmt1.iterate()) {
272271
i--
273-
expect(data).to.deep.equal({
274-
id: i,
275-
b: String(i),
276-
c: i + r
277-
})
278-
}
279-
expect(i).to.equal(0)
272+
expect(data).to.deep.equal({
273+
id: i,
274+
b: String(i),
275+
c: i + r
276+
})
277+
}
278+
expect(i).to.equal(0)
280279
});
281280
});

0 commit comments

Comments
 (0)