From 163b8390d4b23df988c533e5443a479b64f94264 Mon Sep 17 00:00:00 2001 From: Lunar Date: Fri, 26 Aug 2022 10:34:37 +0200 Subject: [PATCH] Update dependencies The only issue was with aruba, a library to run command lines during tests which removed `run_simple` for the more explicit `run_command_and_stop` in version 1.0.0. After updating the step definitions, all tests pass. --- Gemfile.lock | 101 +++++++++++++++----------- features/step_definitions/commands.rb | 4 +- features/step_definitions/git.rb | 20 ++--- features/step_definitions/members.rb | 2 +- 4 files changed, 70 insertions(+), 57 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index b9bb2ac..85c8d27 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -9,51 +9,64 @@ PATH GEM remote: https://rubygems.org/ specs: - aruba (0.14.2) - childprocess (~> 0.5.6) - contracts (~> 0.9) - cucumber (>= 1.3.19) - ffi (~> 1.9.10) - rspec-expectations (>= 2.99) - thor (~> 0.19) - builder (3.2.3) - childprocess (0.5.9) - ffi (~> 1.0, >= 1.0.11) - contracts (0.16.0) - cucumber (2.4.0) - builder (>= 2.1.2) - cucumber-core (~> 1.5.0) - cucumber-wire (~> 0.0.1) - diff-lcs (>= 1.1.3) - gherkin (~> 4.0) - multi_json (>= 1.7.5, < 2.0) - multi_test (>= 0.1.2) - cucumber-core (1.5.0) - gherkin (~> 4.0) - cucumber-wire (0.0.1) - diff-lcs (1.3) - ffi (1.9.18) - gherkin (4.1.3) - json (2.1.0) - mail (2.6.6) - mime-types (>= 1.16, < 4) - mime-types (3.1) + aruba (2.1.0) + bundler (>= 1.17, < 3.0) + childprocess (>= 2.0, < 5.0) + contracts (>= 0.16.0, < 0.18.0) + cucumber (>= 4.0, < 9.0) + rspec-expectations (~> 3.4) + thor (~> 1.0) + builder (3.2.4) + childprocess (4.1.0) + contracts (0.16.1) + cucumber (8.0.0) + builder (~> 3.2, >= 3.2.4) + cucumber-ci-environment (~> 9.0, >= 9.0.4) + cucumber-core (~> 11.0, >= 11.0.0) + cucumber-cucumber-expressions (~> 15.1, >= 15.1.1) + cucumber-gherkin (~> 23.0, >= 23.0.1) + cucumber-html-formatter (~> 19.1, >= 19.1.0) + cucumber-messages (~> 18.0, >= 18.0.0) + diff-lcs (~> 1.5, >= 1.5.0) + mime-types (~> 3.4, >= 3.4.1) + multi_test (~> 1.1, >= 1.1.0) + sys-uname (~> 1.2, >= 1.2.2) + cucumber-ci-environment (9.1.0) + cucumber-core (11.0.0) + cucumber-gherkin (~> 23.0, >= 23.0.1) + cucumber-messages (~> 18.0, >= 18.0.0) + cucumber-tag-expressions (~> 4.1, >= 4.1.0) + cucumber-cucumber-expressions (15.2.0) + cucumber-gherkin (23.0.1) + cucumber-messages (~> 18.0, >= 18.0.0) + cucumber-html-formatter (19.2.0) + cucumber-messages (~> 18.0, >= 18.0.0) + cucumber-messages (18.0.0) + cucumber-tag-expressions (4.1.0) + diff-lcs (1.5.0) + ffi (1.15.5) + json (2.6.2) + mail (2.7.1) + mini_mime (>= 0.1.1) + mime-types (3.4.1) mime-types-data (~> 3.2015) - mime-types-data (3.2016.0521) - multi_json (1.12.2) - multi_test (0.1.2) - pdf-core (0.7.0) - prawn (2.2.2) - pdf-core (~> 0.7.0) - ttfunk (~> 1.5) - rspec-expectations (3.6.0) + mime-types-data (3.2022.0105) + mini_mime (1.1.2) + multi_test (1.1.0) + pdf-core (0.9.0) + prawn (2.4.0) + pdf-core (~> 0.9.0) + ttfunk (~> 1.7) + rspec-expectations (3.11.0) diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.6.0) - rspec-support (3.6.0) - safe_yaml (1.0.4) - thor (0.20.0) - timecop (0.9.1) - ttfunk (1.5.1) + rspec-support (~> 3.11.0) + rspec-support (3.11.0) + safe_yaml (1.0.5) + sys-uname (1.2.2) + ffi (~> 1.1) + thor (1.2.1) + timecop (0.9.5) + ttfunk (1.7.0) PLATFORMS ruby @@ -66,4 +79,4 @@ DEPENDENCIES timecop BUNDLED WITH - 1.13.6 + 2.2.5 diff --git a/features/step_definitions/commands.rb b/features/step_definitions/commands.rb index 622a44b..d4d7ab5 100644 --- a/features/step_definitions/commands.rb +++ b/features/step_definitions/commands.rb @@ -17,7 +17,7 @@ # along with this program. If not, see . When /^j'exécute list\-emails$/ do - run_simple 'list-emails' + run_command_and_stop 'list-emails' end When /^j'exécute list-emails le (\d+)\-(\d+)\-(\d+)$/ do |year, month, day|$/ @@ -58,7 +58,7 @@ When /^j'exécute `create\-membership\-fee\-receipt ([0-9]+) ([0-9,]+)` le ([0-9 end When /^j'exécute `(create\-membership\-fee\-receipt.*)`$/ do |cmd| - run_simple cmd, :fail_on_error => false + run_command_and_stop cmd, :fail_on_error => false end Then /^je ne dois pas avoir eu d'erreur$/ do diff --git a/features/step_definitions/git.rb b/features/step_definitions/git.rb index 3c0e145..eef206e 100644 --- a/features/step_definitions/git.rb +++ b/features/step_definitions/git.rb @@ -23,20 +23,20 @@ Given /^un clone du Git contenant les adhésions$/ do @main_repository_path = expand_path('main') create_directory 'main' cd 'main' - run_simple 'git init --quiet --bare' + run_command_and_stop 'git init --quiet --bare' cd '..' # Clone it now - run_simple "git clone --quiet --local file://#{expand_path('.')}/main clone" + run_command_and_stop "git clone --quiet --local file://#{expand_path('.')}/main clone" cd 'clone' create_directory 'Membres' BASE_MEMBERS.each_pair do |number, data| file = member_filename_for_id(number) File.write file, render_member_file(data) - run_simple "git add #{file}" + run_command_and_stop "git add #{file}" end - run_simple 'git commit -m "Initial data set from fixtures"' - run_simple 'git push --quiet origin master' + run_command_and_stop 'git commit -m "Initial data set from fixtures"' + run_command_and_stop 'git push --quiet origin master' end Given /^le « pre-commit hook » correctement configuré$/ do @@ -50,12 +50,12 @@ Given /^le « pre-receive hook » configuré sur le dépôt principal$/ do end When /je fais un `commit` du nouveau fichier$/ do - run_simple "git add #{@file}" - run_simple "git commit #{@file} -m 'new file'", false # do not fail on error + run_command_and_stop "git add #{@file}" + run_command_and_stop "git commit #{@file} -m 'new file'", :fail_on_error => false # do not fail on error end When /je pousse la modification$/ do - run_simple "git add #{@file}" - run_simple "git commit #{@file} -m 'new file'" - run_simple 'git push origin master', false # do not fail on error + run_command_and_stop "git add #{@file}" + run_command_and_stop "git commit #{@file} -m 'new file'" + run_command_and_stop 'git push origin master', :fail_on_error => false # do not fail on error end diff --git a/features/step_definitions/members.rb b/features/step_definitions/members.rb index 67d31c5..0cde0b5 100644 --- a/features/step_definitions/members.rb +++ b/features/step_definitions/members.rb @@ -210,7 +210,7 @@ end When /^je supprime le nom sur une fiche existante$/ do @file = member_filename_for_id(1) - run_simple "sed -e '/^name:/d' -i #{@file}" + run_command_and_stop "sed -e '/^name:/d' -i #{@file}" end When /^j'ajoute un fichier hors de la base des adhérents$/ do -- 2.39.2