Code Monkey home page Code Monkey logo

Comments (3)

k1LoW avatar k1LoW commented on June 15, 2024

Hi @ajlanghorn !

If the Name tag value is unique in instances, ec2 resource can detect instance by the Name tag value. ( see https://github.com/k1LoW/awspec/blob/master/spec/type/ec2_spec.rb#L34 )

If there are instances with same name tag,

throw Awspec::DuplicatedResourceTypeError

(And see #155 (comment))

from awspec.

ajlanghorn avatar ajlanghorn commented on June 15, 2024

Hi @k1LoW! Thanks; I've got a few instances with the same value for the Name tag, but a different value for a separate tag. I'd love it if I can get something like:

describe ec2('name') do
    it { should have_tag('env').value('production') }
end

to work, because then I can differentiate based on the env tag's value, without changing the rest of my test.

from awspec.

k1LoW avatar k1LoW commented on June 15, 2024

Hi!

I think " *spec (like awspec / RSpec / Serverspec) should detect resource uniquely "

For example

  1. Running instance => Instance ID: i-abcdefg / tag name 'name' / tag env 'production'
  2. Running instance => Instance ID: i-123456 / tag name 'name' / tag env 'development'

Your spec can not report true or false.

So awspec throw Awspec::DuplicatedResourceTypeError.

Best Regards.

from awspec.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.