diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 96c35cddf7e..98a233fd668 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -220,6 +220,10 @@ jobs: if: matrix.build_type == 'system' run: bin/ember-cli --build + - name: Ensure latest minio binary installed for System Tests + if: matrix.build_type == 'system' + run: bundle exec ruby script/install_minio_binaries.rb + - name: Core System Tests if: matrix.build_type == 'system' && matrix.target == 'core' run: RAILS_ENABLE_TEST_LOG=1 RAILS_TEST_LOG_LEVEL=error PARALLEL_TEST_PROCESSORS=4 bin/turbo_rspec --use-runtime-info --profile=50 --verbose --format documentation spec/system diff --git a/app/assets/javascripts/discourse/app/components/avatar-uploader.hbs b/app/assets/javascripts/discourse/app/components/avatar-uploader.hbs index 97fb5cba170..d410bde3f23 100644 --- a/app/assets/javascripts/discourse/app/components/avatar-uploader.hbs +++ b/app/assets/javascripts/discourse/app/components/avatar-uploader.hbs @@ -11,7 +11,7 @@ @disabled={{this.uploading}} @action={{this.chooseImage}} @title="user.change_avatar.upload_title" - class="btn-default" + class="btn-default avatar-uploader__button" data-uploaded={{this.customAvatarUploaded}} data-avatar-upload-id={{this.uploadedAvatarId}} /> diff --git a/spec/support/system_helpers.rb b/spec/support/system_helpers.rb index 87e11c8b0f9..d2e0a4c2748 100644 --- a/spec/support/system_helpers.rb +++ b/spec/support/system_helpers.rb @@ -199,8 +199,6 @@ module SystemHelpers end def skip_unless_s3_system_specs_enabled! - skip("(martin) temporarily skipping minio tests because of parralel binary issues") - if !ENV["CI"] && !ENV["RUN_S3_SYSTEM_SPECS"] skip( "S3 system specs are disabled in this environment, set CI=1 or RUN_S3_SYSTEM_SPECS=1 to enable them.", diff --git a/spec/system/s3_secure_uploads_spec.rb b/spec/system/s3_secure_uploads_spec.rb index 1ab9bcaa276..44d3390553a 100644 --- a/spec/system/s3_secure_uploads_spec.rb +++ b/spec/system/s3_secure_uploads_spec.rb @@ -110,7 +110,13 @@ describe "Uploading files in the composer to S3", type: :system do # Extra wait time is added because the job can slow down the processing of the request. img = first_post_img(wait: 10) - expect(img["src"]).not_to include("/secure-uploads") + + # At first the image will be secure when created via the composer, usually the + # CookedPostProcessor job fixes this but running it immediately when creating the + # post doesn't work in the test, so we need to rebake here to get the correct result. + expect(page).to have_css("img[src*='secure-uploads']") + Post.last.rebake! + expect(page).not_to have_css("img[src*='secure-uploads']", wait: 5) topic = topic_page.current_topic expect(topic.first_post.uploads.first.secure).to eq(false) end diff --git a/spec/system/s3_uploads_spec.rb b/spec/system/s3_uploads_spec.rb index a1f9090be22..71cdc10b77e 100644 --- a/spec/system/s3_uploads_spec.rb +++ b/spec/system/s3_uploads_spec.rb @@ -22,7 +22,7 @@ describe "Uploading files in the composer to S3", type: :system do attach_file(File.absolute_path(file_from_fixtures("logo.jpg"))) do find("#avatar-uploader").click end - expect(page).to have_css(".avatar-uploader label[data-uploaded]") + expect(page).to have_css(".avatar-uploader .avatar-uploader__button[data-uploaded]") modal.click_primary_button expect(modal).to be_closed expect(page).to have_css(