mirror of
https://github.com/internetee/registry.git
synced 2025-05-16 17:37:17 +02:00
Fix tests #2564
This commit is contained in:
parent
b18960c32a
commit
bfe9086ec0
3 changed files with 5 additions and 3 deletions
|
@ -24,7 +24,8 @@ class Epp::DomainsController < EppController
|
|||
authorize! :create, Epp::Domain
|
||||
@domain = Epp::Domain.new_from_epp(params[:parsed_frame], current_user)
|
||||
handle_errors(@domain) and return if @domain.errors.any?
|
||||
handle_errors(@domain) and return if @domain.valid? && @domain.errors.any?
|
||||
@domain.valid?
|
||||
handle_errors(@domain) and return if @domain.errors.any?
|
||||
|
||||
handle_errors and return unless balance_ok?('create')
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ class Epp::SessionsController < EppController
|
|||
success = true
|
||||
@api_user = ApiUser.find_by(login_params)
|
||||
|
||||
if request.ip == ENV['webclient_ip'] && (!Rails.env.test? || !Rails.env.development?)
|
||||
if request.ip == ENV['webclient_ip'] && !Rails.env.test? && !Rails.env.development?
|
||||
client_md5 = Certificate.parse_md_from_string(request.env['HTTP_SSL_CLIENT_CERT'])
|
||||
server_md5 = Certificate.parse_md_from_string(File.read(ENV['cert_path']))
|
||||
if client_md5 != server_md5
|
||||
|
|
|
@ -272,8 +272,9 @@ describe 'EPP Domain', epp: true do
|
|||
xml = domain_create_xml(name: { value: 'ftp.ee' })
|
||||
|
||||
response = epp_plain_request(xml)
|
||||
response[:result_code].should == '2302'
|
||||
response[:msg].should == 'Domain name is blocked [name_dirty]'
|
||||
response[:result_code].should == '2302'
|
||||
response[:results][0][:value].should == 'ftp.ee'
|
||||
response[:clTRID].should == 'ABC-12345'
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue