plucky 0.5.1 → 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -100,7 +100,9 @@ module Plucky
100
100
  end
101
101
 
102
102
  def count(opts={})
103
- find_each(opts).count
103
+ query = clone.amend(opts)
104
+ cursor = query.collection.find(query.criteria.to_hash, query.options.to_hash)
105
+ cursor.count
104
106
  end
105
107
 
106
108
  def size
@@ -224,4 +226,4 @@ module Plucky
224
226
  clone.tap { |query| query.options[:fields] = the_fields}
225
227
  end
226
228
  end
227
- end
229
+ end
@@ -1,4 +1,4 @@
1
1
  # encoding: UTF-8
2
2
  module Plucky
3
- Version = '0.5.1'
3
+ Version = '0.5.2'
4
4
  end
@@ -1,16 +1,3 @@
1
- def growl(title, msg, img)
2
- %x{growlnotify -m #{ msg.inspect} -t #{title.inspect} --image ~/.watchr/#{img}.png}
3
- end
4
-
5
- def form_growl_message(str)
6
- results = str.split("\n").last
7
- if results =~ /[1-9]\s(failure|error)s?/
8
- growl "Test Results", "#{results}", "fail"
9
- elsif results != ""
10
- growl "Test Results", "#{results}", "pass"
11
- end
12
- end
13
-
14
1
  def run(cmd)
15
2
  puts(cmd)
16
3
  output = ""
@@ -21,7 +8,6 @@ def run(cmd)
21
8
  $stdout.flush
22
9
  end
23
10
  end
24
- form_growl_message output
25
11
  end
26
12
 
27
13
  def run_test_file(file)
metadata CHANGED
@@ -1,47 +1,34 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: plucky
3
- version: !ruby/object:Gem::Version
4
- hash: 9
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.5.2
5
5
  prerelease:
6
- segments:
7
- - 0
8
- - 5
9
- - 1
10
- version: 0.5.1
11
6
  platform: ruby
12
- authors:
7
+ authors:
13
8
  - John Nunemaker
14
9
  autorequire:
15
10
  bindir: bin
16
11
  cert_chain: []
17
-
18
- date: 2012-04-24 00:00:00 Z
19
- dependencies:
20
- - !ruby/object:Gem::Dependency
21
- type: :runtime
22
- prerelease: false
23
- requirement: &id001 !ruby/object:Gem::Requirement
12
+ date: 2012-09-12 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: mongo
16
+ requirement: &70317435688340 !ruby/object:Gem::Requirement
24
17
  none: false
25
- requirements:
18
+ requirements:
26
19
  - - ~>
27
- - !ruby/object:Gem::Version
28
- hash: 5
29
- segments:
30
- - 1
31
- - 5
32
- version: "1.5"
33
- version_requirements: *id001
34
- name: mongo
20
+ - !ruby/object:Gem::Version
21
+ version: '1.5'
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: *70317435688340
35
25
  description:
36
- email:
26
+ email:
37
27
  - nunemaker@gmail.com
38
28
  executables: []
39
-
40
29
  extensions: []
41
-
42
30
  extra_rdoc_files: []
43
-
44
- files:
31
+ files:
45
32
  - .gitignore
46
33
  - .travis.yml
47
34
  - Gemfile
@@ -75,38 +62,30 @@ files:
75
62
  - test/test_symbol_operator.rb
76
63
  homepage: http://jnunemaker.github.com/plucky/
77
64
  licenses: []
78
-
79
65
  post_install_message:
80
66
  rdoc_options: []
81
-
82
- require_paths:
67
+ require_paths:
83
68
  - lib
84
- required_ruby_version: !ruby/object:Gem::Requirement
69
+ required_ruby_version: !ruby/object:Gem::Requirement
85
70
  none: false
86
- requirements:
87
- - - ">="
88
- - !ruby/object:Gem::Version
89
- hash: 3
90
- segments:
91
- - 0
92
- version: "0"
93
- required_rubygems_version: !ruby/object:Gem::Requirement
71
+ requirements:
72
+ - - ! '>='
73
+ - !ruby/object:Gem::Version
74
+ version: '0'
75
+ required_rubygems_version: !ruby/object:Gem::Requirement
94
76
  none: false
95
- requirements:
96
- - - ">="
97
- - !ruby/object:Gem::Version
98
- hash: 3
99
- segments:
100
- - 0
101
- version: "0"
77
+ requirements:
78
+ - - ! '>='
79
+ - !ruby/object:Gem::Version
80
+ version: '0'
102
81
  requirements: []
103
-
104
82
  rubyforge_project:
105
83
  rubygems_version: 1.8.10
106
84
  signing_key:
107
85
  specification_version: 3
108
- summary: Thin layer over the ruby driver that allows you to quickly grab hold of your data (pluck it!).
109
- test_files:
86
+ summary: Thin layer over the ruby driver that allows you to quickly grab hold of your
87
+ data (pluck it!).
88
+ test_files:
110
89
  - test/helper.rb
111
90
  - test/plucky/pagination/test_decorator.rb
112
91
  - test/plucky/pagination/test_paginator.rb