Skip to content

Mysql throws error when app name contains emoji #3719

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions spec/request/space_manifests_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,36 @@
)
end


context 'when the manifest contains valid binary-encoded URL(s) for the buildpack(s)' do
let(:app1_model) { VCAP::CloudController::AppModel.make(name: '🦄🦄🦄', space: space) }
let(:yml_manifest_with_binary_valid_buildpacks) do
"---
applications:
- name: #{app1_model.name}
buildpacks:
- !!binary |-
aHR0cHM6Ly9naXRodWIuY29tL2Nsb3VkZm91bmRyeS9uZ2lueC1idWlsZHBhY2suZ2l0
- !!binary |-
aHR0cHM6Ly9naXRodWIuY29tL2J1aWxkcGFja3MvbXktc3BlY2lhbC1idWlsZHBhY2s="
end

it 'applies the manifest' do
post "/v3/spaces/#{space.guid}/actions/apply_manifest", yml_manifest_with_binary_valid_buildpacks, yml_headers(user_header)
expect(last_response.status).to eq(202)
job_guid = VCAP::CloudController::PollableJobModel.last.guid
expect(last_response.headers['Location']).to match(%r{/v3/jobs/#{job_guid}})

Delayed::Worker.new.work_off
expect(VCAP::CloudController::PollableJobModel.find(guid: job_guid)).to be_complete, VCAP::CloudController::PollableJobModel.find(guid: job_guid).cf_api_error

app1_model.reload
lifecycle_data = app1_model.lifecycle_data
expect(lifecycle_data.buildpacks.first).to include('https://github.com/cloudfoundry/nginx-buildpack.git')
expect(lifecycle_data.buildpacks.second).to include('https://github.com/buildpacks/my-special-buildpack')
end
end

context 'service bindings' do
let(:client) { instance_double(VCAP::Services::ServiceBrokers::V2::Client, bind: {}) }

Expand Down
Loading