soar-registry-directory 0.0.1 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 74f2f96f3112e94b32dbdf1df3158d4a7c90c243
4
- data.tar.gz: bc374da550aeac5dfb1141a3e306aa6d3c2e0bbc
3
+ metadata.gz: a4505d2bbb4a6b9d47b370ddeaf82d8a9b76231b
4
+ data.tar.gz: e4de04def83d9751931f30eb49e9fcaad7acd61c
5
5
  SHA512:
6
- metadata.gz: c685cac5ebf8519e8115d4f3fbb96860c3221caf1f01a4f60600e4700201f9effc54bd73cbe4fb80b1d0c8f493526f556ca59c720fd28f8db8260e81b01f2401
7
- data.tar.gz: 598ec60e756b7a7d185d679632c7ea1649fee116d6e78d7792956ff1c824a277790fa9fedd9d3fe45dbe6e8fe33517549dacc0da999211ae42248c3eaa652f03
6
+ metadata.gz: 44514a249b7af19f67f784abe25868d644bfd91a70e777078a0aa613954c196bab77e915b5270be35b2146e29a9ea22fcc31860854c7eb704ef0a7688864e153
7
+ data.tar.gz: 715d8a78da3f01196c2a67d61fe78bcb059fe86458cd3f6d270f318cfb2de46ba66d57731d8753972d3d1bb7b06ed6bdf32cda651a9e053d87b1102d1607330e
data/README.md CHANGED
@@ -47,7 +47,7 @@ Create an instance of the stub provider by passing in the name, primary key and
47
47
 
48
48
  ### The Model
49
49
  ```ruby
50
- > directory = Soar::Registry::Directory.new(provider: provider)
50
+ > directory = Soar::Registry::Directory.new(provider)
51
51
  ```
52
52
 
53
53
  ## Tests
@@ -12,7 +12,7 @@ module Soar
12
12
  ##
13
13
  # @param provider [Soar::Registry::Directory::Provider::Stub|Soar::Registry::Directory::Provider::DynamoDb] object
14
14
  ##
15
- def initialize(provider: nil)
15
+ def initialize(provider)
16
16
  @provider = provider
17
17
  end
18
18
 
@@ -15,15 +15,14 @@ module Soar
15
15
  end
16
16
 
17
17
  def given_configured_directory
18
- @directory = Soar::Registry::Directory.new({
19
- provider: Soar::Registry::Directory::Provider::DynamoDb.new({
20
- credentials: @configuration['provider']['credentials'],
21
- table: @table,
22
- index: @index,
23
- primary_key: @index[0],
24
- configuration: @configuration['provider']['config']
25
- })
18
+ provider = Soar::Registry::Directory::Provider::DynamoDb.new({
19
+ credentials: @configuration['provider']['credentials'],
20
+ table: @table,
21
+ index: @index,
22
+ primary_key: @index[0],
23
+ configuration: @configuration['provider']['config']
26
24
  })
25
+ @directory = Soar::Registry::Directory.new(provider)
27
26
  @directory.provider.recreate_table({
28
27
  name: @table,
29
28
  structure: JSON.parse(File.read("lib/soar/registry/directory/test/fixtures/table_structure.json"))
@@ -15,13 +15,12 @@ module Soar
15
15
  @@index = ["identity_id", "email", "entity_id"]
16
16
 
17
17
  def given_configured_directory
18
- @directory = Soar::Registry::Directory.new({
19
- provider: Soar::Registry::Directory::Provider::Stub.new({
20
- table: "identities",
21
- primary_key: "uuid",
22
- index: @@index
23
- })
18
+ provider = Soar::Registry::Directory::Provider::Stub.new({
19
+ table: "identities",
20
+ primary_key: "uuid",
21
+ index: @@index
24
22
  })
23
+ @directory = Soar::Registry::Directory.new(provider)
25
24
  end
26
25
 
27
26
  def given_existing_data
@@ -3,8 +3,8 @@ require "soar/registry/directory/model"
3
3
  module Soar
4
4
  module Registry
5
5
  module Directory
6
- def self.new(provider: nil)
7
- Soar::Registry::Directory::Model.new(provider: provider)
6
+ def self.new(provider)
7
+ Soar::Registry::Directory::Model.new(provider)
8
8
  end
9
9
  end
10
10
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: soar-registry-directory
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Charles Mulder
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-11-30 00:00:00.000000000 Z
11
+ date: 2016-12-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: hashy_db