Skip to content

Commit 7259441

Browse files
committed
Fix lint errors in find_users.test.js
1 parent 500f1e3 commit 7259441

File tree

1 file changed

+49
-49
lines changed

1 file changed

+49
-49
lines changed

tests-app/find_users.test.js

Lines changed: 49 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -3,68 +3,68 @@
33
// When running in isolation, both tests pass
44
// When running only one, both work, too
55
// describe('users - find hooks', function () {
6-
// it('should be capable of being used on special Meteor.users collection', async function () {
6+
// it('should be capable of being used on special Meteor.users collection', async function () {
77

8-
// const aspect1 = Meteor.users.before.find(function (userId, selector, options) {
9-
// if (selector && selector.test) {
10-
// selector.a = 1
11-
// }
12-
// })
8+
// const aspect1 = Meteor.users.before.find(function (userId, selector, options) {
9+
// if (selector && selector.test) {
10+
// selector.a = 1
11+
// }
12+
// })
1313

14-
// const aspect2 = Meteor.users.after.find(function (userId, selector, options) {
15-
// if (selector && selector.test) {
16-
// selector.b = 1
17-
// }
18-
// })
14+
// const aspect2 = Meteor.users.after.find(function (userId, selector, options) {
15+
// if (selector && selector.test) {
16+
// selector.b = 1
17+
// }
18+
// })
1919

20-
// const selector = { test: 1 }
20+
// const selector = { test: 1 }
2121

22-
// const cursor = Meteor.users.find(selector)
22+
// const cursor = Meteor.users.find(selector)
2323

24-
// expect(Object.prototype.hasOwnProperty.call(selector, 'a')).toBe(true)
25-
// expect(Object.prototype.hasOwnProperty.call(selector, 'b')).toBe(true)
26-
// aspect1.remove()
27-
// aspect2.remove()
24+
// expect(Object.prototype.hasOwnProperty.call(selector, 'a')).toBe(true)
25+
// expect(Object.prototype.hasOwnProperty.call(selector, 'b')).toBe(true)
26+
// aspect1.remove()
27+
// aspect2.remove()
2828

29-
// })
29+
// })
3030

31-
// it('should be capable of being used on wrapped Meteor.users collection', async function () {
32-
// function TestUser (doc) {
33-
// return Object.assign(this, doc)
34-
// }
31+
// it('should be capable of being used on wrapped Meteor.users collection', async function () {
32+
// function TestUser (doc) {
33+
// return Object.assign(this, doc)
34+
// }
3535

36-
// Meteor.users.__transform = doc => new TestUser(doc)
36+
// Meteor.users.__transform = doc => new TestUser(doc)
3737

38-
// const MeteorUsersFind = Meteor.users.find
38+
// const MeteorUsersFind = Meteor.users.find
3939

40-
// Meteor.users.find = function (selector = {}, options = {}) {
41-
// return MeteorUsersFind.call(this, selector, { transform: Meteor.users.__transform, ...options })
42-
// }
40+
// Meteor.users.find = function (selector = {}, options = {}) {
41+
// return MeteorUsersFind.call(this, selector, { transform: Meteor.users.__transform, ...options })
42+
// }
4343

44-
// // eslint-disable-next-line array-callback-return
45-
// const aspect1 = Meteor.users.before.find(function (userId, selector, options) {
46-
// if (selector && selector.test) {
47-
// selector.a = 1
48-
// }
49-
// })
44+
// // eslint-disable-next-line array-callback-return
45+
// const aspect1 = Meteor.users.before.find(function (userId, selector, options) {
46+
// if (selector && selector.test) {
47+
// selector.a = 1
48+
// }
49+
// })
5050

51-
// // eslint-disable-next-line array-callback-return
52-
// const aspect2 = Meteor.users.after.find(function (userId, selector, options) {
53-
// if (selector && selector.test) {
54-
// selector.b = 1
55-
// }
56-
// })
51+
// // eslint-disable-next-line array-callback-return
52+
// const aspect2 = Meteor.users.after.find(function (userId, selector, options) {
53+
// if (selector && selector.test) {
54+
// selector.b = 1
55+
// }
56+
// })
5757

58-
// const selector = { test: 1 }
59-
// Meteor.users.find(selector)
60-
// expect(Object.prototype.hasOwnProperty.call(selector, 'a')).toBe(true)
61-
// expect(Object.prototype.hasOwnProperty.call(selector, 'b')).toBe(true)
62-
// aspect1.remove()
63-
// aspect2.remove()
58+
// const selector = { test: 1 }
59+
// Meteor.users.find(selector)
60+
// expect(Object.prototype.hasOwnProperty.call(selector, 'a')).toBe(true)
61+
// expect(Object.prototype.hasOwnProperty.call(selector, 'b')).toBe(true)
62+
// aspect1.remove()
63+
// aspect2.remove()
6464

65-
// // Remove this line - it's not testing hook functionality
66-
// // expect(await Meteor.users.find().countAsync()).not.toBe(0)
65+
// // Remove this line - it's not testing hook functionality
66+
// // expect(await Meteor.users.find().countAsync()).not.toBe(0)
6767

68-
// Meteor.users.find = MeteorUsersFind
69-
// })
68+
// Meteor.users.find = MeteorUsersFind
69+
// })
7070
// })

0 commit comments

Comments
 (0)