juno 0.2.4 → 0.2.5
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +7 -2
- data/README.md +4 -2
- data/lib/juno/adapters/memcached_native.rb +3 -1
- data/lib/juno/builder.rb +4 -5
- data/lib/juno/cache.rb +6 -4
- data/lib/juno/expires.rb +4 -0
- data/lib/juno/lock.rb +8 -1
- data/lib/juno/logger.rb +86 -0
- data/lib/juno/proxy.rb +4 -0
- data/lib/juno/stack.rb +3 -2
- data/lib/juno/transformer.rb +61 -61
- data/lib/juno/version.rb +1 -1
- data/lib/juno.rb +10 -8
- data/spec/adapter_activerecord_spec.rb +2 -2
- data/spec/adapter_cassandra_spec.rb +1 -1
- data/spec/adapter_couch_spec.rb +1 -1
- data/spec/adapter_datamapper_spec.rb +1 -1
- data/spec/adapter_dbm_spec.rb +1 -1
- data/spec/adapter_file_spec.rb +1 -1
- data/spec/adapter_fog_spec.rb +1 -1
- data/spec/adapter_gdbm_spec.rb +1 -1
- data/spec/adapter_localmemcache_spec.rb +1 -1
- data/spec/adapter_lruhash_spec.rb +1 -1
- data/spec/adapter_memcached_dalli_spec.rb +1 -1
- data/spec/adapter_memcached_native_spec.rb +1 -1
- data/spec/adapter_memcached_spec.rb +1 -1
- data/spec/adapter_memory_spec.rb +1 -1
- data/spec/adapter_mongo_spec.rb +1 -1
- data/spec/adapter_pstore_spec.rb +1 -1
- data/spec/adapter_redis_spec.rb +1 -1
- data/spec/adapter_riak_spec.rb +1 -1
- data/spec/adapter_sdbm_spec.rb +1 -1
- data/spec/adapter_sequel_spec.rb +1 -1
- data/spec/adapter_sqlite_spec.rb +1 -1
- data/spec/adapter_tokyocabinet_bdb_spec.rb +1 -1
- data/spec/adapter_tokyocabinet_hdb_spec.rb +1 -1
- data/spec/adapter_yaml_spec.rb +1 -1
- data/spec/cache_file_memory_spec.rb +1 -1
- data/spec/cache_memory_null_spec.rb +1 -1
- data/spec/expires_file_spec.rb +1 -1
- data/spec/expires_memory_spec.rb +1 -1
- data/spec/generate.rb +37 -12
- data/spec/junospecs.rb +1 -1
- data/spec/lock_spec.rb +1 -1
- data/spec/null_adapter_spec.rb +1 -1
- data/spec/proxy_expires_memory_spec.rb +1 -1
- data/spec/proxy_redis_spec.rb +1 -1
- data/spec/simple_activerecord_spec.rb +2 -2
- data/spec/simple_activerecord_with_expires_spec.rb +2 -2
- data/spec/simple_cassandra_spec.rb +2 -2
- data/spec/simple_couch_spec.rb +2 -2
- data/spec/simple_couch_with_expires_spec.rb +2 -2
- data/spec/simple_datamapper_spec.rb +2 -2
- data/spec/simple_datamapper_with_expires_spec.rb +2 -2
- data/spec/simple_datamapper_with_repository_spec.rb +2 -2
- data/spec/simple_dbm_spec.rb +2 -2
- data/spec/simple_dbm_with_expires_spec.rb +2 -2
- data/spec/simple_file_spec.rb +2 -2
- data/spec/simple_file_with_expires_spec.rb +2 -2
- data/spec/simple_fog_spec.rb +2 -2
- data/spec/simple_fog_with_expires_spec.rb +2 -2
- data/spec/simple_gdbm_spec.rb +2 -2
- data/spec/simple_gdbm_with_expires_spec.rb +2 -2
- data/spec/simple_hashfile_spec.rb +2 -2
- data/spec/simple_hashfile_with_expires_spec.rb +2 -2
- data/spec/simple_localmemcache_spec.rb +2 -2
- data/spec/simple_localmemcache_with_expires_spec.rb +2 -2
- data/spec/simple_lruhash_spec.rb +2 -2
- data/spec/simple_lruhash_with_expires_spec.rb +2 -2
- data/spec/simple_memcached_dalli_spec.rb +2 -2
- data/spec/simple_memcached_native_spec.rb +2 -2
- data/spec/simple_memcached_spec.rb +2 -2
- data/spec/simple_memory_spec.rb +2 -2
- data/spec/simple_memory_with_expires_spec.rb +2 -2
- data/spec/simple_mongo_spec.rb +2 -2
- data/spec/simple_mongo_with_expires_spec.rb +2 -2
- data/spec/simple_null_spec.rb +2 -2
- data/spec/simple_pstore_spec.rb +2 -2
- data/spec/simple_pstore_with_expires_spec.rb +2 -2
- data/spec/simple_redis_spec.rb +2 -2
- data/spec/simple_riak_spec.rb +2 -2
- data/spec/simple_riak_with_expires_spec.rb +2 -2
- data/spec/simple_sdbm_spec.rb +2 -2
- data/spec/simple_sdbm_with_expires_spec.rb +2 -2
- data/spec/simple_sequel_spec.rb +2 -2
- data/spec/simple_sequel_with_expires_spec.rb +2 -2
- data/spec/simple_sqlite_spec.rb +2 -2
- data/spec/simple_sqlite_with_expires_spec.rb +2 -2
- data/spec/simple_tokyocabinet_spec.rb +2 -2
- data/spec/simple_tokyocabinet_with_expires_spec.rb +2 -2
- data/spec/simple_yaml_spec.rb +2 -2
- data/spec/simple_yaml_with_expires_spec.rb +2 -2
- data/spec/stack_file_memory_spec.rb +1 -1
- data/spec/stack_memory_file_spec.rb +1 -1
- data/spec/transformer_bencode_spec.rb +25 -0
- data/spec/transformer_bert_spec.rb +25 -0
- data/spec/transformer_bson_spec.rb +1 -1
- data/spec/transformer_compress_spec.rb +1 -1
- data/spec/transformer_json_spec.rb +1 -1
- data/spec/transformer_marshal_base64_spec.rb +1 -1
- data/spec/transformer_marshal_escape_spec.rb +1 -1
- data/spec/transformer_marshal_md5_spec.rb +1 -1
- data/spec/transformer_marshal_md5_spread_spec.rb +1 -1
- data/spec/transformer_marshal_uuencode_spec.rb +41 -0
- data/spec/transformer_msgpack_spec.rb +1 -1
- data/spec/transformer_ox_spec.rb +1 -1
- data/spec/transformer_tnet_spec.rb +25 -0
- data/spec/transformer_yaml_spec.rb +1 -1
- metadata +11 -2
data/spec/adapter_riak_spec.rb
CHANGED
data/spec/adapter_sdbm_spec.rb
CHANGED
data/spec/adapter_sequel_spec.rb
CHANGED
data/spec/adapter_sqlite_spec.rb
CHANGED
data/spec/adapter_yaml_spec.rb
CHANGED
data/spec/expires_file_spec.rb
CHANGED
data/spec/expires_memory_spec.rb
CHANGED
data/spec/generate.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
ADAPTER_SPECS = [:null_stringkey_stringvalue, :store_stringkey_stringvalue, :returndifferent_stringkey_stringvalue]
|
2
2
|
SIMPLE_SPECS = [:null, :store, :returndifferent, :marshallable_key]
|
3
3
|
EXPIRES_SPECS = SIMPLE_SPECS + [:expires_stringkey_stringvalue]
|
4
|
-
header = "# Generated by #{__FILE__}
|
4
|
+
header = "# Generated by #{__FILE__}\n"
|
5
5
|
|
6
6
|
TESTS = {
|
7
7
|
'simple_memory' => {
|
@@ -344,6 +344,24 @@ end},
|
|
344
344
|
:build => %{Juno.build do
|
345
345
|
use :Transformer, :key => :json, :value => :json
|
346
346
|
adapter :Memory
|
347
|
+
end},
|
348
|
+
:key => %w(Hash String),
|
349
|
+
:value => %w(Hash String),
|
350
|
+
:specs => [:null, :store, :returndifferent]
|
351
|
+
},
|
352
|
+
'transformer_bert' => {
|
353
|
+
:build => %{Juno.build do
|
354
|
+
use :Transformer, :key => :bert, :value => :bert
|
355
|
+
adapter :Memory
|
356
|
+
end},
|
357
|
+
:key => %w(Hash String),
|
358
|
+
:value => %w(Hash String),
|
359
|
+
:specs => [:null, :store, :returndifferent]
|
360
|
+
},
|
361
|
+
'transformer_bencode' => {
|
362
|
+
:build => %{Juno.build do
|
363
|
+
use :Transformer, :key => :bencode, :value => :bencode
|
364
|
+
adapter :Memory
|
347
365
|
end},
|
348
366
|
:key => %w(Hash String),
|
349
367
|
:value => %w(Hash String),
|
@@ -365,15 +383,15 @@ end},
|
|
365
383
|
end},
|
366
384
|
:specs => [:null, :store, :returndifferent]
|
367
385
|
},
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
386
|
+
'transformer_tnet' => {
|
387
|
+
:build => %{Juno.build do
|
388
|
+
use :Transformer, :key => :tnet, :value => :tnet
|
389
|
+
adapter :Memory
|
390
|
+
end},
|
391
|
+
:key => %w(Hash String),
|
392
|
+
:value => %w(Hash String),
|
393
|
+
:specs => [:null, :store, :returndifferent]
|
394
|
+
},
|
377
395
|
'transformer_msgpack' => {
|
378
396
|
:build => %{Juno.build do
|
379
397
|
use :Transformer, :key => :msgpack, :value => :msgpack
|
@@ -394,6 +412,13 @@ end},
|
|
394
412
|
:build => %{Juno.build do
|
395
413
|
use :Transformer, :key => [:marshal, :base64], :value => [:marshal, :base64]
|
396
414
|
adapter :Memory
|
415
|
+
end},
|
416
|
+
:specs => [:null, :store, :returndifferent, :marshallable_key]
|
417
|
+
},
|
418
|
+
'transformer_marshal_uuencode' => {
|
419
|
+
:build => %{Juno.build do
|
420
|
+
use :Transformer, :key => [:marshal, :uuencode], :value => [:marshal, :uuencode]
|
421
|
+
adapter :Memory
|
397
422
|
end},
|
398
423
|
:specs => [:null, :store, :returndifferent, :marshallable_key]
|
399
424
|
},
|
@@ -433,7 +458,7 @@ it 'uses an existing connection' do
|
|
433
458
|
ActiveRecord::Base.establish_connection :adapter => (defined?(JRUBY_VERSION) ? 'jdbcsqlite3' : 'sqlite3'), :database => File.join(make_tempdir, 'activerecord-existing')
|
434
459
|
|
435
460
|
store = Juno::Adapters::ActiveRecord.new
|
436
|
-
store.table.
|
461
|
+
store.table.should be_table_exists
|
437
462
|
end
|
438
463
|
}
|
439
464
|
},
|
@@ -830,7 +855,7 @@ TESTS.each do |name, options|
|
|
830
855
|
opts = options.delete(:options)
|
831
856
|
opts = ', ' << opts if opts
|
832
857
|
|
833
|
-
build ||= "Juno.new(#{store.inspect}#{opts})"
|
858
|
+
build ||= "Juno.new(#{store.inspect}#{opts}, :logger => {:out => File.open(File.join(make_tempdir, '#{name}.log'), 'a')})"
|
834
859
|
|
835
860
|
code = %{#{header}require 'helper'
|
836
861
|
|
data/spec/junospecs.rb
CHANGED
data/spec/lock_spec.rb
CHANGED
data/spec/null_adapter_spec.rb
CHANGED
data/spec/proxy_redis_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_activerecord" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:ActiveRecord, :connection => { :adapter => (defined?(JRUBY_VERSION) ? 'jdbcsqlite3' : 'sqlite3'), :database => File.join(make_tempdir, 'simple_activerecord') })
|
6
|
+
Juno.new(:ActiveRecord, :connection => { :adapter => (defined?(JRUBY_VERSION) ? 'jdbcsqlite3' : 'sqlite3'), :database => File.join(make_tempdir, 'simple_activerecord') }, :logger => {:out => File.open(File.join(make_tempdir, 'simple_activerecord.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_activerecord_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:ActiveRecord, :connection => { :adapter => (defined?(JRUBY_VERSION) ? 'jdbcsqlite3' : 'sqlite3'), :database => File.join(make_tempdir, 'simple_activerecord_with_expires') }, :expires => true)
|
6
|
+
Juno.new(:ActiveRecord, :connection => { :adapter => (defined?(JRUBY_VERSION) ? 'jdbcsqlite3' : 'sqlite3'), :database => File.join(make_tempdir, 'simple_activerecord_with_expires') }, :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_activerecord_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_cassandra" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Cassandra)
|
6
|
+
Juno.new(:Cassandra, :logger => {:out => File.open(File.join(make_tempdir, 'simple_cassandra.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
data/spec/simple_couch_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_couch" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Couch, :db => 'simple_couch')
|
6
|
+
Juno.new(:Couch, :db => 'simple_couch', :logger => {:out => File.open(File.join(make_tempdir, 'simple_couch.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_couch_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Couch, :db => 'simple_couch_with_expires', :expires => true)
|
6
|
+
Juno.new(:Couch, :db => 'simple_couch_with_expires', :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_couch_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,11 +1,11 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_datamapper" do
|
5
5
|
require 'dm-core'
|
6
6
|
DataMapper.setup(:default, :adapter => :in_memory)
|
7
7
|
def new_store
|
8
|
-
Juno.new(:DataMapper, :setup => "sqlite3://#{make_tempdir}/simple_datamapper")
|
8
|
+
Juno.new(:DataMapper, :setup => "sqlite3://#{make_tempdir}/simple_datamapper", :logger => {:out => File.open(File.join(make_tempdir, 'simple_datamapper.log'), 'a')})
|
9
9
|
end
|
10
10
|
|
11
11
|
include_context 'setup_store'
|
@@ -1,11 +1,11 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_datamapper_with_expires" do
|
5
5
|
require 'dm-core'
|
6
6
|
DataMapper.setup(:default, :adapter => :in_memory)
|
7
7
|
def new_store
|
8
|
-
Juno.new(:DataMapper, :setup => "sqlite3://#{make_tempdir}/simple_datamapper_with_expires", :expires => true)
|
8
|
+
Juno.new(:DataMapper, :setup => "sqlite3://#{make_tempdir}/simple_datamapper_with_expires", :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_datamapper_with_expires.log'), 'a')})
|
9
9
|
end
|
10
10
|
|
11
11
|
include_context 'setup_store'
|
@@ -1,11 +1,11 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_datamapper_with_repository" do
|
5
5
|
require 'dm-core'
|
6
6
|
DataMapper.setup(:default, :adapter => :in_memory)
|
7
7
|
def new_store
|
8
|
-
Juno.new(:DataMapper, :repository => :repo, :setup => "sqlite3://#{make_tempdir}/simple_datamapper_with_repository")
|
8
|
+
Juno.new(:DataMapper, :repository => :repo, :setup => "sqlite3://#{make_tempdir}/simple_datamapper_with_repository", :logger => {:out => File.open(File.join(make_tempdir, 'simple_datamapper_with_repository.log'), 'a')})
|
9
9
|
end
|
10
10
|
|
11
11
|
include_context 'setup_store'
|
data/spec/simple_dbm_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_dbm" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:DBM, :file => File.join(make_tempdir, "simple_dbm"))
|
6
|
+
Juno.new(:DBM, :file => File.join(make_tempdir, "simple_dbm"), :logger => {:out => File.open(File.join(make_tempdir, 'simple_dbm.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_dbm_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:DBM, :file => File.join(make_tempdir, "simple_dbm_with_expires"), :expires => true)
|
6
|
+
Juno.new(:DBM, :file => File.join(make_tempdir, "simple_dbm_with_expires"), :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_dbm_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
data/spec/simple_file_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_file" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:File, :dir => File.join(make_tempdir, "simple_file"))
|
6
|
+
Juno.new(:File, :dir => File.join(make_tempdir, "simple_file"), :logger => {:out => File.open(File.join(make_tempdir, 'simple_file.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_file_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:File, :dir => File.join(make_tempdir, "simple_file_with_expires"), :expires => true)
|
6
|
+
Juno.new(:File, :dir => File.join(make_tempdir, "simple_file_with_expires"), :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_file_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
data/spec/simple_fog_spec.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_fog" do
|
@@ -8,7 +8,7 @@ describe_juno "simple_fog" do
|
|
8
8
|
Juno.new(:Fog, :aws_access_key_id => 'fake_access_key_id',
|
9
9
|
:aws_secret_access_key => 'fake_secret_access_key',
|
10
10
|
:provider => 'AWS',
|
11
|
-
:dir => 'juno')
|
11
|
+
:dir => 'juno', :logger => {:out => File.open(File.join(make_tempdir, 'simple_fog.log'), 'a')})
|
12
12
|
end
|
13
13
|
|
14
14
|
include_context 'setup_store'
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_fog_with_expires" do
|
@@ -9,7 +9,7 @@ describe_juno "simple_fog_with_expires" do
|
|
9
9
|
:aws_secret_access_key => 'fake_secret_access_key',
|
10
10
|
:provider => 'AWS',
|
11
11
|
:dir => 'juno',
|
12
|
-
:expires => true)
|
12
|
+
:expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_fog_with_expires.log'), 'a')})
|
13
13
|
end
|
14
14
|
|
15
15
|
include_context 'setup_store'
|
data/spec/simple_gdbm_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_gdbm" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:GDBM, :file => File.join(make_tempdir, "simple_gdbm"))
|
6
|
+
Juno.new(:GDBM, :file => File.join(make_tempdir, "simple_gdbm"), :logger => {:out => File.open(File.join(make_tempdir, 'simple_gdbm.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_gdbm_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:GDBM, :file => File.join(make_tempdir, "simple_gdbm_with_expires"), :expires => true)
|
6
|
+
Juno.new(:GDBM, :file => File.join(make_tempdir, "simple_gdbm_with_expires"), :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_gdbm_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_hashfile" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:HashFile, :dir => File.join(make_tempdir, "simple_hashfile"))
|
6
|
+
Juno.new(:HashFile, :dir => File.join(make_tempdir, "simple_hashfile"), :logger => {:out => File.open(File.join(make_tempdir, 'simple_hashfile.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_hashfile_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:HashFile, :dir => File.join(make_tempdir, "simple_hashfile_with_expires"), :expires => true)
|
6
|
+
Juno.new(:HashFile, :dir => File.join(make_tempdir, "simple_hashfile_with_expires"), :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_hashfile_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_localmemcache" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:LocalMemCache, :file => File.join(make_tempdir, "simple_localmemcache"))
|
6
|
+
Juno.new(:LocalMemCache, :file => File.join(make_tempdir, "simple_localmemcache"), :logger => {:out => File.open(File.join(make_tempdir, 'simple_localmemcache.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_localmemcache_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:LocalMemCache, :file => File.join(make_tempdir, "simple_localmemcache_with_expires"), :expires => true)
|
6
|
+
Juno.new(:LocalMemCache, :file => File.join(make_tempdir, "simple_localmemcache_with_expires"), :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_localmemcache_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
data/spec/simple_lruhash_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_lruhash" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:LRUHash)
|
6
|
+
Juno.new(:LRUHash, :logger => {:out => File.open(File.join(make_tempdir, 'simple_lruhash.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_lruhash_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:LRUHash, :expires => true)
|
6
|
+
Juno.new(:LRUHash, :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_lruhash_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_memcached_dalli" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:MemcachedDalli, :namespace => "simple_memcached_dalli")
|
6
|
+
Juno.new(:MemcachedDalli, :namespace => "simple_memcached_dalli", :logger => {:out => File.open(File.join(make_tempdir, 'simple_memcached_dalli.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_memcached_native" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:MemcachedNative, :namespace => "simple_memcached_native")
|
6
|
+
Juno.new(:MemcachedNative, :namespace => "simple_memcached_native", :logger => {:out => File.open(File.join(make_tempdir, 'simple_memcached_native.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_memcached" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Memcached, :namespace => "simple_memcached")
|
6
|
+
Juno.new(:Memcached, :namespace => "simple_memcached", :logger => {:out => File.open(File.join(make_tempdir, 'simple_memcached.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
data/spec/simple_memory_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_memory" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Memory)
|
6
|
+
Juno.new(:Memory, :logger => {:out => File.open(File.join(make_tempdir, 'simple_memory.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_memory_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Memory, :expires => true)
|
6
|
+
Juno.new(:Memory, :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_memory_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
data/spec/simple_mongo_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_mongo" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Mongo, :db => 'simple_mongo')
|
6
|
+
Juno.new(:Mongo, :db => 'simple_mongo', :logger => {:out => File.open(File.join(make_tempdir, 'simple_mongo.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_mongo_with_expires" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Mongo, :db => 'simple_mongo_with_expires', :expires => true)
|
6
|
+
Juno.new(:Mongo, :db => 'simple_mongo_with_expires', :expires => true, :logger => {:out => File.open(File.join(make_tempdir, 'simple_mongo_with_expires.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
data/spec/simple_null_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_null" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:Null)
|
6
|
+
Juno.new(:Null, :logger => {:out => File.open(File.join(make_tempdir, 'simple_null.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|
data/spec/simple_pstore_spec.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
|
-
# Generated by generate.rb
|
1
|
+
# Generated by generate.rb
|
2
2
|
require 'helper'
|
3
3
|
|
4
4
|
describe_juno "simple_pstore" do
|
5
5
|
def new_store
|
6
|
-
Juno.new(:PStore, :file => File.join(make_tempdir, "simple_pstore"))
|
6
|
+
Juno.new(:PStore, :file => File.join(make_tempdir, "simple_pstore"), :logger => {:out => File.open(File.join(make_tempdir, 'simple_pstore.log'), 'a')})
|
7
7
|
end
|
8
8
|
|
9
9
|
include_context 'setup_store'
|