aws-int-test-rspec-helper 0.0.4 → 0.0.5

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: c1eaf67566d3c149fafee4541c1d39cb2d070f16
4
- data.tar.gz: cd225d71f27ca9ef9aba0413be710ed16cecdbe0
3
+ metadata.gz: f680275f6d5ef500bca1006943d8c1159e2610e7
4
+ data.tar.gz: 5fc5e56fc17fe012a30be33f9b9420d3ba39c674
5
5
  SHA512:
6
- metadata.gz: ee1df83f9e73421bf474632ffe24fddc17706fe6326fa4dbdeb85e13e56fefbb2ac0ecf24812d785e2bd4ae14416365ff161a7364b5e36401290b80fe4da4790
7
- data.tar.gz: df900eac941fb7b9af30067f81fc454edba396cdcea94c9c9b599fe15766a06a82e8f662ff8d3a5d5da420ce4bb09fd6e37d93b6e7c72c5b3d4379dad7b51b6f
6
+ metadata.gz: a26034fa5c189c632d49422f40d417d9dc52df7e0e378bf133a064a3f03b5668212e99bfc378b8f4b236a15a882fce245b9152cdbf5db0d3c6caa532d35325a1
7
+ data.tar.gz: cc41bf1460577c104ce7922009994c775a7f89b2ab23bc9b61ee2c391a5bb86f0e41da3097b8635d43526354bfd249e1418e761debcc3d223bd3bed5242b3fc6
@@ -3,12 +3,32 @@ require 'cfndsl'
3
3
  require 'rspec'
4
4
  require 'tempfile'
5
5
 
6
+ ##
7
+ # Some methods to make integration testing AWS SDK code a bit more convenient.
8
+ # Easily create AWS resources with cfndsl specifications as part of RSpec tests.
9
+ #
6
10
  module AwsIntTestRspecHelper
7
11
 
12
+ ##
13
+ # Delete the specified Cloudformation stack by name
14
+ #
8
15
  def cleanup(cloudformation_stack_name)
9
16
  Aws::CloudFormation::Client.new.delete_stack(stack_name: cloudformation_stack_name)
10
17
  end
11
18
 
19
+ ##
20
+ # Creates a Cloudformation stack.
21
+ #
22
+ # To elaborate, this will create a stack from a cfndsl file and wait until the stack creation is
23
+ # completed (or failed). You can optionally parameterise the stack with a Hash.
24
+ # The outputs of the stack are available by referencing #stack_outputs. The return value
25
+ # of the method is the full stack name that is created.
26
+ #
27
+ # * +stack_name+ - a stem for the name of the stack to create. the final name of the stack
28
+ # will be this concatenated with a timestamp
29
+ # * +path_to_stack+ - this is the path to a cfndsl file to create the stack from
30
+ # * +bindings+ - this is an optional Hash of variables that fill in variables in the cfndsl stack
31
+ # this is how you can parameterise the stack (without Parameters)
12
32
  def stack(stack_name:,
13
33
  path_to_stack:,
14
34
  bindings: nil)
@@ -48,7 +68,9 @@ module AwsIntTestRspecHelper
48
68
  full_stack_name
49
69
  end
50
70
 
51
-
71
+ ##
72
+ # Returns a Hash of the Cloudformation stack outputs
73
+ #
52
74
  def stack_outputs
53
75
  @stack_outputs
54
76
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-int-test-rspec-helper
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - someguy
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-04 00:00:00.000000000 Z
11
+ date: 2016-03-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk
@@ -59,8 +59,9 @@ extensions: []
59
59
  extra_rdoc_files: []
60
60
  files:
61
61
  - lib/aws-int-test-rspec-helper.rb
62
- homepage:
63
- licenses: []
62
+ homepage: https://github.com/stelligent/aws-int-test-rspec-helper
63
+ licenses:
64
+ - MIT
64
65
  metadata: {}
65
66
  post_install_message:
66
67
  rdoc_options: []
@@ -70,7 +71,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
70
71
  requirements:
71
72
  - - ">="
72
73
  - !ruby/object:Gem::Version
73
- version: '0'
74
+ version: 2.1.0
74
75
  required_rubygems_version: !ruby/object:Gem::Requirement
75
76
  requirements:
76
77
  - - ">="