title: Exclude gem warnings in rake tests without removing warnings from own code
body: <p>In our current Ruby (ruby 2.4.2p131, installed by rbenv as 2.4.0-dev) (NOT Rails) project we use a number of gems that produce warnings. I appreciate warnings that are caused by our own code and want to see and remove them, but there is not much to be done about warnings from gems. Is there a way to show only our own warnings?</p>
  
  <p>I searched for similar questions, but they either require Rails, or want to disable ALL warnings. Both doesn't meet our requirements.</p>
  
  <p>I also tried the warning gem (<a href="https://rubygems.org/gems/warning/versions/0.10.0" rel="nofollow noreferrer">https://rubygems.org/gems/warning/versions/0.10.0</a>) but failed to produce any change with it.</p>
  
  <p><strong>EDIT</strong>
  Here is two of the warnings that I don't want to see:<br>
  <code>aws-sdk-resources-2.9.8/lib/aws-sdk-resources/services/s3/object.rb:61: warning: method redefined; discarding old copy_from</code>  </p>
  
  <p><code>aws-sdk-core-2.9.8/lib/aws-sdk-core/plugins/s3_accelerate.rb:75: warning: assigned but unused variable - ssl</code></p>