Class: DeloreanTestBed::Cache
- Inherits:
-
Object
- Object
- DeloreanTestBed::Cache
- Defined in:
- lib/delorean_test_bed/cache.rb
Class Method Summary collapse
-
.cache ⇒ Object
Set our own cache or read the setup one.
- .read(k) ⇒ Object
- .write(k, v) ⇒ Object
Class Method Details
.cache ⇒ Object
Set our own cache or read the setup one
8 9 10 |
# File 'lib/delorean_test_bed/cache.rb', line 8 def self.cache ActiveSupport::Cache.lookup_store(Rails.application.config.cache_store) end |
.read(k) ⇒ Object
16 17 18 |
# File 'lib/delorean_test_bed/cache.rb', line 16 def self.read(k) cache.read([:delorean,:key]) end |
.write(k, v) ⇒ Object
12 13 14 |
# File 'lib/delorean_test_bed/cache.rb', line 12 def self.write(k,v) cache.write([:delorean,:key],v) end |