From 30c0a4ace9faa2fd78b49a0d10bf0bb016d3d5f2 Mon Sep 17 00:00:00 2001 From: Oleg Hasjanov Date: Fri, 26 May 2023 14:06:09 +0300 Subject: [PATCH] fixed tests --- .github/workflows/ruby.yml | 1 - app/controllers/users_controller.rb | 2 +- app/views/auctions/_auction.html.erb | 2 +- app/views/common/_header.html.erb | 4 +- app/views/devise/sessions/new.html.erb | 2 +- app/views/users/show.html.erb | 2 +- package.json | 3 - test/integration/english_offers_test.rb | 38 +++--- test/integration/offers_test.rb | 1 + test/system/admin/admin_auctions_test.rb | 32 ++--- .../admin/users/admin_users_list_test.rb | 5 +- .../admin/users/admin_users_profile_test.rb | 28 +++-- test/system/bans_test.rb | 4 +- test/system/billing_profiles_test.rb | 6 +- test/system/email_confirmations_test.rb | 7 +- test/system/english_offers_test.rb | 8 +- test/system/invoices_test.rb | 8 +- test/system/offers/billing_offers_test.rb | 8 +- test/system/offers/recaptcha_offers_test.rb | 12 +- test/system/phone_confirmations_test.rb | 2 +- test/system/sessions_test.rb | 4 +- test/system/users/create_user_test.rb | 8 +- test/system/users/edit_user_test.rb | 116 +++++++++--------- test/system/users/locale_test.rb | 46 +++---- test/system/users/tara_users_test.rb | 54 ++++---- 25 files changed, 221 insertions(+), 182 deletions(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index 3154105b5..e04472d8e 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -84,7 +84,6 @@ jobs: bundle exec rake data:migrate bundle exec rails assets:precompile bundle exec rails test test/* - yarn test - name: Save coverage run: ./cc-test-reporter format-coverage --output coverage/codeclimate.${{ matrix.ruby }}.json diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index a23febbbb..c6efe8d81 100644 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -87,7 +87,7 @@ def update def destroy respond_to do |format| if @user.deletable? && @user.destroy! - format.html { redirect_to :root, notice: notification_for_delete(@user) } + format.html { redirect_to root_path, notice: notification_for_delete(@user) } else format.html { redirect_to user_path(@user.uuid), notice: notification_for_delete(@user) } end diff --git a/app/views/auctions/_auction.html.erb b/app/views/auctions/_auction.html.erb index 8c38da037..44e112854 100644 --- a/app/views/auctions/_auction.html.erb +++ b/app/views/auctions/_auction.html.erb @@ -1,7 +1,7 @@ <% english_auction_presenter = EnglishBidsPresenter.new(auction) %> - <%= link_to auction_path(auction.uuid) do %> + <%= link_to auction_path(auction.uuid), target: '_top' do %> <%= domain_name_with_embedded_colors(auction.domain_name) %> <% end %> diff --git a/app/views/common/_header.html.erb b/app/views/common/_header.html.erb index 4a71daf60..954e4f318 100644 --- a/app/views/common/_header.html.erb +++ b/app/views/common/_header.html.erb @@ -32,11 +32,11 @@