deltacloud-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Lutterkort <lut...@redhat.com>
Subject Re: [PATCH 1/2] API TESTS - moves common collections tests to separate file
Date Thu, 02 Aug 2012 00:13:14 GMT
On Wed, 2012-08-01 at 14:38 +0300, marios@redhat.com wrote:
> From: marios <marios@redhat.com>
> 
> 
> Signed-off-by: marios <marios@redhat.com>
> ---
>  tests/deltacloud/buckets_test.rb             |  135 ++++++++++----------------
>  tests/deltacloud/common_tests_collections.rb |  105 ++++++++++++++++++++
>  tests/deltacloud/test_setup.rb               |   23 ++++-
>  3 files changed, 178 insertions(+), 85 deletions(-)
>  create mode 100644 tests/deltacloud/common_tests_collections.rb
> 
> diff --git a/tests/deltacloud/buckets_test.rb b/tests/deltacloud/buckets_test.rb
> index e8732b1..e16e743 100644
> --- a/tests/deltacloud/buckets_test.rb
> +++ b/tests/deltacloud/buckets_test.rb
> @@ -61,19 +61,63 @@ describe 'Deltacloud API buckets collection' do
>      end
>    }
>  
> -  it 'must advertise the buckets collection in API entrypoint' do
> +  #Run the 'common' tests for all collections defined in common_tests_collections.rb
> +  test_collection = "buckets"
> +  $:.unshift File.join(File.dirname(__FILE__), '..')
> +  eval File.read('deltacloud/common_tests_collections.rb')

NAK; can we define these common tests in a module and include that ?

David



Mime
View raw message