diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f2cfffa22..d06d716b4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -30,13 +30,10 @@ jobs: ruby-version: 2.7.2 bundler-cache: true - - name: Use Node.js 14.x + - name: Use Node.js 16.x uses: actions/setup-node@v2 with: - node-version: 14.x - - - name: Use latest npm - run: npm install -g npm + node-version: 16.x - name: Install bundler & bundle-audit run: | @@ -91,13 +88,10 @@ jobs: ruby-version: 2.7.2 bundler-cache: true - - name: Use Node.js 14.x + - name: Use Node.js 16.x uses: actions/setup-node@v2 with: - node-version: 14.x - - - name: Use latest npm - run: npm install -g npm + node-version: 16.x - name: Install bundler & bundle-audit run: | diff --git a/Dockerfile b/Dockerfile index dbedccb76..4013a65f7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,7 +14,7 @@ RUN bash -lc "rvm install ruby-${RUBY_VERSION} && rvm --default use ruby-${RUBY_ RUN rm -f /etc/service/nginx/down \ && rm -f /etc/nginx/sites-enabled/default \ && apt update \ - && curl -fsSL https://deb.nodesource.com/setup_14.x | bash - \ + && curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \ && apt-get install -y nodejs \ && npm install -g npm@latest \ && apt-get install shared-mime-info -y diff --git a/Gemfile.lock b/Gemfile.lock index ef242fcae..7afbe7e0f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,6 +1,6 @@ GIT remote: https://github.com/projecttacoma/cqm-parsers.git - revision: baa3e9a50b376e29a47956f5cfb7c5ebe49fc9dd + revision: 50891071760b46b70d120e5f3cc752c258cf2c69 branch: bonnie-prior-version specs: cqm-parsers (0.2.1.1) diff --git a/app/assets/javascripts/views/import_measure_view.js.coffee b/app/assets/javascripts/views/import_measure_view.js.coffee index 93496bffc..556ccc8fc 100644 --- a/app/assets/javascripts/views/import_measure_view.js.coffee +++ b/app/assets/javascripts/views/import_measure_view.js.coffee @@ -72,11 +72,6 @@ class Thorax.Views.ImportMeasure extends Thorax.Views.BonnieView $('#vsac-query-settings').removeClass('hidden') $('#vsacCachedMsg').removeClass('hidden') $('#loadButton').prop('disabled', false) - # If the measure import window is open long enough for the VSAC - # credentials to expire, we need to reshow the vsacApiKey dialog. - setTimeout -> - @clearCachedVSACTicket() - , new Date(data.expires) - new Date() else $('#vsacSignIn').removeClass('hidden') $('#vsac-query-settings').removeClass('hidden') diff --git a/app/controllers/api_v1/measures_controller.rb b/app/controllers/api_v1/measures_controller.rb index 9bcfc3611..21e120ace 100644 --- a/app/controllers/api_v1/measures_controller.rb +++ b/app/controllers/api_v1/measures_controller.rb @@ -81,8 +81,7 @@ def description param :population_titles, Array, of: String, :required => false, :desc => "The titles of the populations. If this is not included, populations will assume default values. i.e. \"Population 1\", \"Population 2\", etc." param :calculate_sdes, %w[true false], :required => false, :desc => "Should Supplemental Data Elements be included in calculations. Defaults to 'false' if not supplied." - param :vsac_tgt, String, :required => true, :desc => "VSAC ticket granting ticket. See https://www.nlm.nih.gov/vsac/support/" - param :vsac_tgt_expires_at, Integer, :required => true, :desc => "VSAC ticket granting ticket expiration time in seconds since epoch." + param :vsac_api_key, String, :required => true, :desc => "UMLS Api Key." param :vsac_query_type, %w[release profile], :required => false, :desc => "The type of VSAC query, either 'release', or 'profile'. Default to 'profile' if not supplied." param :vsac_query_include_draft, %w[true false], :required => false, :desc => "If VSAC should fetch draft value sets. Defaults to 'true' if not supplied." param :vsac_query_release, String, :required => false, :desc => "The program release used to retrieve value sets. Defaults to latest release for the eCQM program." @@ -210,7 +209,7 @@ def calculated_results formats ["multipart/form-data"] error :code => 400, :desc => "Client sent bad parameters. Response contains explanation." error :code => 409, :desc => "Measure with this HQMF Set ID already exists." - error :code => 500, :desc => "A server error occured." + error :code => 500, :desc => "A server error occurred." param_group :measure_upload def create permitted_params = params.permit!.to_h @@ -229,7 +228,7 @@ def create formats ["multipart/form-data"] error :code => 400, :desc => "Client sent bad parameters. Response contains explanation." error :code => 404, :desc => "Measure with this HQMF Set ID does not exist." - error :code => 500, :desc => "A server error occured." + error :code => 500, :desc => "A server error occurred." param_group :measure_upload def update measures, main_hqmf_set_id = update_measure(uploaded_file: params[:measure_file], diff --git a/app/controllers/measures_controller.rb b/app/controllers/measures_controller.rb index 4b56f11d9..4ee920ddc 100644 --- a/app/controllers/measures_controller.rb +++ b/app/controllers/measures_controller.rb @@ -31,7 +31,7 @@ def create begin scan_for_viruses(params[:measure_file]) - vsac_tgt = obtain_ticket_granting_ticket + set_vsac_api_key rescue VirusFoundError => e logger.error "VIRSCAN: error message: #{e.message}" raise MeasurePackageVirusFoundError.new @@ -43,13 +43,11 @@ def create raise convert_vsac_error_into_shared_error(e) end - params[:vsac_tgt] = vsac_tgt[:ticket] - params[:vsac_tgt_expires_at] = vsac_tgt[:expires] measures, main_hqmf_set_id = persist_measure(params[:measure_file], params.permit!.to_h, current_user) redirect_to "#{root_path}##{params[:redirect_route]}" rescue StandardError => e - # also clear the ticket granting ticket in the session if it was a VSACTicketExpiredError - session[:vsac_tgt] = nil if e.is_a?(VSACTicketExpiredError) + # also clear the vsac api key in the session if it was a VSACInvalidCredentialsError + session[:vsac_api_key] = nil if e.is_a?(VSACInvalidCredentialsError) flash[:error] = turn_exception_into_shared_error_if_needed(e).front_end_version redirect_to "#{root_path}##{params[:redirect_route]}" end @@ -162,6 +160,15 @@ def retrieve_measure_details(params) } end + def set_vsac_api_key + if session[:vsac_api_key].nil? + raise Util::VSAC::VSACNoCredentialsError.new if params[:vsac_api_key].nil? + session[:vsac_api_key] = params[:vsac_api_key] + else + params[:vsac_api_key] = session[:vsac_api_key] + end + end + def shift_years(measure, year_shift) # Copy the patients to make sure there are no errors before saving every patient patients = CQM::Patient.by_user_and_hqmf_set_id(current_user, measure.hqmf_set_id).all.entries @@ -202,33 +209,4 @@ def shift_birth_datetime(birth_datetime, year_shift) birth_datetime.change(year: year_shift + birth_datetime.year) end end - - def obtain_ticket_granting_ticket - # Retreive a (possibly) existing ticket granting ticket - ticket_granting_ticket = session[:vsac_tgt] - - # If the ticket granting ticket doesn't exist (or has expired), get a new one - if ticket_granting_ticket.nil? - # The user could open a second browser window and remove their ticket_granting_ticket in the session after they - # prepared a measure upload assuming ticket_granting_ticket in the session in the first tab - - # First make sure we have credentials to attempt getting a ticket with. Throw an error if there are no credentials. - if params[:vsac_api_key].nil? - raise Util::VSAC::VSACNoCredentialsError.new - end - - # Retrieve a new ticket granting ticket by creating the api class. - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: params[:vsac_api_key]) - ticket_granting_ticket = api.ticket_granting_ticket - - # Create a new ticket granting ticket session variable - session[:vsac_tgt] = ticket_granting_ticket - return ticket_granting_ticket - - # If it does exist, let the api test it - else - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], ticket_granting_ticket: ticket_granting_ticket) - return api.ticket_granting_ticket - end - end end diff --git a/app/controllers/vsac_util_controller.rb b/app/controllers/vsac_util_controller.rb index 32c439f51..25c995fb2 100644 --- a/app/controllers/vsac_util_controller.rb +++ b/app/controllers/vsac_util_controller.rb @@ -51,26 +51,20 @@ def program_release_names ## # GET /vsac_util/auth_valid # - # Gets the status of the ticket_granting_ticket in the session. Returns JSON: - # { valid: boolean, expires: DateTime } + # Gets the status of the API KEY in the session. Returns JSON: + # { valid: boolean } def auth_valid - # If VSAC TGT is still valid, return its expiration date/time - ticket_granting_ticket = session[:vsac_tgt] + vsac_api_key = session[:vsac_api_key] - # If there is no VSAC ticket granting ticket then return false. - if ticket_granting_ticket.nil? || ticket_granting_ticket.empty? - session[:vsac_tgt] = nil - render :json => {valid: false} - - # If it exists then check it using the API + if vsac_api_key.nil? || vsac_api_key.empty? + session[:vsac_api_key] = nil + render :json => {valid:false} else begin - Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], ticket_granting_ticket: ticket_granting_ticket) - render :json => {valid: true, expires: ticket_granting_ticket[:expires]} - - # API will throw an error if it has expired - rescue Util::VSAC::VSACTicketExpiredError - session[:vsac_tgt] = nil + # Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: vsac_api_key) + render :json => {valid: true} + rescue Util::VSAC::VSACInvalidCredentialsError + session[:vsac_api_key] = nil render :json => {valid: false} end end @@ -79,10 +73,10 @@ def auth_valid ## # POST /vsac_util/auth_expire # - # Dumps the ticket_granting_ticket in the user session if there is one. Always returns JSON {}. + # Sets the vsac_api_key in the user session to nil. Always returns JSON {}. def auth_expire # Force expire the VSAC session - session[:vsac_tgt] = nil + session[:vsac_api_key] = nil render :json => {} end end diff --git a/app/helpers/measure_helper.rb b/app/helpers/measure_helper.rb index e9a863b88..5180abb1d 100644 --- a/app/helpers/measure_helper.rb +++ b/app/helpers/measure_helper.rb @@ -256,11 +256,9 @@ def retrieve_vasc_options(params, get_defaults_from_vsac = false) end def build_vs_loader(params, get_defaults_from_vsac) - vsac_tgt_object = {ticket: params[:vsac_tgt], expires: Time.at(params[:vsac_tgt_expires_at].to_i)} if params[:vsac_tgt].present? && params[:vsac_tgt_expires_at].present? - - return Measures::VSACValueSetLoader.new( + Measures::VSACValueSetLoader.new( options: retrieve_vasc_options(params, get_defaults_from_vsac), - ticket_granting_ticket: vsac_tgt_object + vsac_api_key: params[:vsac_api_key] ) end @@ -270,8 +268,6 @@ def convert_vsac_error_into_shared_error(error) return VSACVSLoadingError.new(error.oid) elsif error.is_a?(Util::VSAC::VSACInvalidCredentialsError) return VSACInvalidCredentialsError.new - elsif error.is_a?(Util::VSAC::VSACTicketExpiredError) - return VSACTicketExpiredError.new elsif error.is_a?(Util::VSAC::VSACNoCredentialsError) return VSACNoCredentialsError.new else diff --git a/config/bonnie.yml b/config/bonnie.yml index 3be37b140..33ca81ab8 100644 --- a/config/bonnie.yml +++ b/config/bonnie.yml @@ -1,5 +1,5 @@ defaults: &defaults - version: 4.3.1 + version: 4.3.2 enable_logging: true enable_rationale: true check_crosswalk: false diff --git a/deployment/maintenance.html b/deployment/maintenance.html index e56fbe9de..abc4208a9 100644 --- a/deployment/maintenance.html +++ b/deployment/maintenance.html @@ -2,7 +2,7 @@ - Bonnie v4.3.1 - Service Interruption + Bonnie v4.3.2 - Service Interruption \n\n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n
HQMF SET IDCMS IDTitle
7B2A9277-43DA-4D99-9BEE-6AC271A07747CMS134v6Diabetes: Medical Attention for NephropathyJSONCalculated Results
\n\n
", "code": "200", "show_in_doc": 1, "recorded": true @@ -431,7 +33855,14 @@ "1" ], "query": null, - "request_data": "Content-Type: multipart/form-data; boundary=APIPIE_RECORDER_EXAMPLE_BOUNDARY\n\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_query_type\"\nContent-Length: 7\n\nprofile\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_query_profile\"\nContent-Length: 11\n\nLatest eCQM\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_query_measure_defined\"\nContent-Length: 4\n\ntrue\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_tgt\"\nContent-Length: 65\n\nTGT-229792-vaQWUba1FcYreJsEW3vZpLrae9U6vObfqnC6mcysoa7obbL5zg-cas\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_tgt_expires_at\"\nContent-Length: 10\n\n1589254986\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"measure_file\"; filename=\"IETCQL_v5_0_Artifacts.zip\"\nContent-Length: 36765\nContent-Type: application/zip\nContent-Transfer-Encoding: binary\n\n... contents of \"measure_file\" ...\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"calculation_type\"\nContent-Length: 7\n\nepisode\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY--", + "request_data": { + "vsac_query_type": "profile", + "vsac_query_profile": "Latest eCQM", + "vsac_query_measure_defined": "true", + "vsac_api_key": "vcrpass", + "measure_file": "", + "calculation_type": "episode" + }, "response_data": { "status": "error", "messages": "No measure found for this HQMF Set ID." @@ -447,12 +33878,25 @@ "1" ], "query": null, - "request_data": "Content-Type: multipart/form-data; boundary=APIPIE_RECORDER_EXAMPLE_BOUNDARY\n\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"calculation_type\"\nContent-Length: 7\n\nepisode\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"measure_file\"; filename=\"CMS903v0.zip\"\nContent-Length: 26016\nContent-Type: application/zip\nContent-Transfer-Encoding: binary\n\n... contents of \"measure_file\" ...\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"population_titles[]\"\n\nFoo\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"population_titles[]\"\n\nbar\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"population_titles[]\"\n\nbaz\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"population_titles[]\"\n\nbam\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_query_measure_defined\"\nContent-Length: 4\n\ntrue\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_query_profile\"\nContent-Length: 11\n\nLatest eCQM\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_query_type\"\nContent-Length: 7\n\nprofile\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_tgt\"\nContent-Length: 66\n\nTGT-1609324-E4NK175OUeS0ixzo4WAPxPaNzuHVMvaYuJkzBkLbLgVRfY2Sy1-cas\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY\nContent-Disposition: form-data; name=\"vsac_tgt_expires_at\"\nContent-Length: 10\n\n1589254987\n--APIPIE_RECORDER_EXAMPLE_BOUNDARY--", + "request_data": { + "vsac_query_type": "profile", + "vsac_query_profile": "Latest eCQM", + "vsac_query_measure_defined": "true", + "vsac_api_key": "vcrpass", + "measure_file": "", + "calculation_type": "episode", + "population_titles": [ + "Foo", + "bar", + "baz", + "bam" + ] + }, "response_data": { - "status": "success", - "url": "/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076" + "status": "error", + "messages": "The measure could not be loaded, Bonnie has encountered an error while trying to load the measure." }, - "code": "200", + "code": "500", "show_in_doc": 1, "recorded": true } @@ -10454,5 +43898,22 @@ "show_in_doc": 1, "recorded": true } + ], + "vsac_util#auth_valid": [ + { + "verb": "GET", + "path": "/vsac_util/auth_valid", + "versions": [ + + ], + "query": "", + "request_data": null, + "response_data": { + "valid": true + }, + "code": "200", + "show_in_doc": 1, + "recorded": true + } ] } \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 371b00e6b..093a78827 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "bonnie", - "version": "4.3.1", + "version": "4.3.2", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "bonnie", - "version": "4.3.1", + "version": "4.3.2", "license": "Apache-2.0", "dependencies": { "browserify": "^17.0.0", diff --git a/package.json b/package.json index 6de3a5c69..12f56b0d4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "bonnie", - "version": "4.3.1", + "version": "4.3.2", "description": "A tool for testing electronic clinical quality measures", "main": "index.js", "repository": "git@github.com:MeasureAuthoringTool/bonnie.git", diff --git a/test/fixtures/vcr_cassettes/api_ccdelookback_vsac_response.yml b/test/fixtures/vcr_cassettes/api_ccdelookback_vsac_response.yml index 24b2dd852..b44d697c0 100644 --- a/test/fixtures/vcr_cassettes/api_ccdelookback_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/api_ccdelookback_vsac_response.yml @@ -3188,4 +3188,69 @@ http_interactions: http_version: recorded_at: Tue, 16 Jul 2019 11:59:41 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 25 Jun 2019 22:14:54 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_incorrect_hqmf_vsac_response.yml b/test/fixtures/vcr_cassettes/api_incorrect_hqmf_vsac_response.yml index 8c7fed8e0..b080f1e91 100644 --- a/test/fixtures/vcr_cassettes/api_incorrect_hqmf_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/api_incorrect_hqmf_vsac_response.yml @@ -99,4 +99,69 @@ http_interactions: AM"}' http_version: recorded_at: Tue, 16 Jul 2019 11:59:42 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_invalid_release_vsac_response.yml b/test/fixtures/vcr_cassettes/api_invalid_release_vsac_response.yml index 3813c7dd8..7d53ee4d5 100644 --- a/test/fixtures/vcr_cassettes/api_invalid_release_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/api_invalid_release_vsac_response.yml @@ -1110,4 +1110,69 @@ http_interactions: http_version: recorded_at: Tue, 25 Jun 2019 23:35:27 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 25 Jun 2019 22:14:54 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_missing_vs_vsac_response.yml b/test/fixtures/vcr_cassettes/api_missing_vs_vsac_response.yml index b312a4339..94fe85bf1 100644 --- a/test/fixtures/vcr_cassettes/api_missing_vs_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/api_missing_vs_vsac_response.yml @@ -99,4 +99,69 @@ http_interactions: AM"}' http_version: recorded_at: Tue, 16 Jul 2019 11:59:42 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 25 Jun 2019 22:14:54 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_release_ccdelookback_vsac_response.yml b/test/fixtures/vcr_cassettes/api_release_ccdelookback_vsac_response.yml index c1be086b6..5e6dc04d2 100644 --- a/test/fixtures/vcr_cassettes/api_release_ccdelookback_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/api_release_ccdelookback_vsac_response.yml @@ -15015,4 +15015,69 @@ http_interactions: \ \n\n" http_version: recorded_at: Tue, 16 Jul 2019 11:59:47 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_valid_vsac_response.yml b/test/fixtures/vcr_cassettes/api_valid_vsac_response.yml index d813929f2..b1fb75e4a 100644 --- a/test/fixtures/vcr_cassettes/api_valid_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/api_valid_vsac_response.yml @@ -935,6 +935,71 @@ http_interactions: http_version: recorded_at: Tue, 25 Jun 2019 22:14:54 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 25 Jun 2019 22:14:54 GMT - request: method: get uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113883.3.117.1.7.1.87&includeDraft=yes&profile=Latest%20eCQM&ticket=ST-6400509-v9SaJRJcOEXDglnGeiVQ-cas diff --git a/test/fixtures/vcr_cassettes/api_valid_vsac_response_def_titles.yml b/test/fixtures/vcr_cassettes/api_valid_vsac_response_def_titles.yml index d02d5c864..e69251225 100644 --- a/test/fixtures/vcr_cassettes/api_valid_vsac_response_def_titles.yml +++ b/test/fixtures/vcr_cassettes/api_valid_vsac_response_def_titles.yml @@ -3166,4 +3166,69 @@ http_interactions: http_version: recorded_at: Tue, 25 Jun 2019 23:06:14 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 25 Jun 2019 22:14:54 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_valid_vsac_response_initial.yml b/test/fixtures/vcr_cassettes/api_valid_vsac_response_initial.yml index dd499d587..9188e07f1 100644 --- a/test/fixtures/vcr_cassettes/api_valid_vsac_response_initial.yml +++ b/test/fixtures/vcr_cassettes/api_valid_vsac_response_initial.yml @@ -3166,4 +3166,69 @@ http_interactions: http_version: recorded_at: Tue, 25 Jun 2019 23:33:12 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_valid_vsac_response_non_exist_measure.yml b/test/fixtures/vcr_cassettes/api_valid_vsac_response_non_exist_measure.yml index 40e5d25c1..b235655ed 100644 --- a/test/fixtures/vcr_cassettes/api_valid_vsac_response_non_exist_measure.yml +++ b/test/fixtures/vcr_cassettes/api_valid_vsac_response_non_exist_measure.yml @@ -99,4 +99,69 @@ http_interactions: AM"}' http_version: recorded_at: Tue, 16 Jul 2019 11:59:48 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_valid_vsac_response_provided_titles.yml b/test/fixtures/vcr_cassettes/api_valid_vsac_response_provided_titles.yml index 64702eaa7..c83a88aed 100644 --- a/test/fixtures/vcr_cassettes/api_valid_vsac_response_provided_titles.yml +++ b/test/fixtures/vcr_cassettes/api_valid_vsac_response_provided_titles.yml @@ -3166,4 +3166,69 @@ http_interactions: http_version: recorded_at: Tue, 25 Jun 2019 23:14:40 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/api_valid_vsac_response_update.yml b/test/fixtures/vcr_cassettes/api_valid_vsac_response_update.yml index bea37cb54..a2d07ce0e 100644 --- a/test/fixtures/vcr_cassettes/api_valid_vsac_response_update.yml +++ b/test/fixtures/vcr_cassettes/api_valid_vsac_response_update.yml @@ -3166,4 +3166,69 @@ http_interactions: http_version: recorded_at: Tue, 25 Jun 2019 23:38:12 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/initial_response.yml b/test/fixtures/vcr_cassettes/initial_response.yml index 699f8f3cf..06a5e0707 100644 --- a/test/fixtures/vcr_cassettes/initial_response.yml +++ b/test/fixtures/vcr_cassettes/initial_response.yml @@ -3116,4 +3116,69 @@ http_interactions: http_version: recorded_at: Wed, 07 Aug 2019 15:54:09 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/invalid_vsac_response.yml b/test/fixtures/vcr_cassettes/invalid_vsac_response.yml index 26ddd1292..6591c6235 100644 --- a/test/fixtures/vcr_cassettes/invalid_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/invalid_vsac_response.yml @@ -1,52 +1,68 @@ --- http_interactions: -- request: - method: post - uri: https://vsac.nlm.nih.gov/vsac/ws/Ticket - body: - encoding: US-ASCII - string: username=invaliduser&password=invalidpassword - headers: - User-Agent: - - Typhoeus - https://github.com/typhoeus/typhoeus - Expect: - - '' - response: - status: - code: 401 - message: '' - headers: - X-Frame-Options: - - SAMEORIGIN - X-Content-Type-Options: - - nosniff - - nosniff - X-Xss-Protection: - - 1; mode=block - Cache-Control: - - no-cache, no-store, max-age=0, must-revalidate - Pragma: - - no-cache - Expires: - - '0' - Content-Type: - - text/plain;charset=utf-8 - Transfer-Encoding: - - chunked - Date: - - Tue, 16 Jul 2019 11:59:19 GMT - Set-Cookie: - - BIGipServervsacweb_p=!eRqM2NtZ2n18tE3NtNHn4GsLooFbU14UxvXhOnb5GWb4ylVopzXHM4r2xBCn3zJQUKSYkRsA1WagRrA=; - expires=Tue, 16-Jul-2019 13:59:19 GMT; path=/; Httponly; Secure - X-Vip-Info: - - 130.14.16.40:443 - X-Pool-Info: - - "/Common/vsacweb_p 10.1.5.114 8080" - Strict-Transport-Security: - - max-age=31536000; includeSubDomains; preload - body: - encoding: UTF-8 - string: '' - http_version: - recorded_at: Tue, 16 Jul 2019 11:59:19 GMT + - request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 401 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/mat_5_4_valid_vsac_response.yml b/test/fixtures/vcr_cassettes/mat_5_4_valid_vsac_response.yml index ed5bf3224..c70027819 100644 --- a/test/fixtures/vcr_cassettes/mat_5_4_valid_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/mat_5_4_valid_vsac_response.yml @@ -4844,4 +4844,69 @@ http_interactions: http_version: recorded_at: Tue, 16 Jul 2019 11:59:17 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/measure_destroy.yml b/test/fixtures/vcr_cassettes/measure_destroy.yml index f996934a6..56ee87f24 100644 --- a/test/fixtures/vcr_cassettes/measure_destroy.yml +++ b/test/fixtures/vcr_cassettes/measure_destroy.yml @@ -11782,4 +11782,69 @@ http_interactions: http_version: recorded_at: Wed, 07 Aug 2019 17:16:36 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/measure_loading_does_not_alter_expected_values.yml b/test/fixtures/vcr_cassettes/measure_loading_does_not_alter_expected_values.yml index f79044973..6583da511 100644 --- a/test/fixtures/vcr_cassettes/measure_loading_does_not_alter_expected_values.yml +++ b/test/fixtures/vcr_cassettes/measure_loading_does_not_alter_expected_values.yml @@ -3513,4 +3513,69 @@ http_interactions: http_version: recorded_at: Tue, 30 Jul 2019 13:46:23 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/measure_show.yml b/test/fixtures/vcr_cassettes/measure_show.yml index e265a89d7..f2f1e8472 100644 --- a/test/fixtures/vcr_cassettes/measure_show.yml +++ b/test/fixtures/vcr_cassettes/measure_show.yml @@ -4844,4 +4844,69 @@ http_interactions: http_version: recorded_at: Tue, 16 Jul 2019 11:59:02 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/profile_draft_query.yml b/test/fixtures/vcr_cassettes/profile_draft_query.yml index 52bbd02cc..7be8ec7ba 100644 --- a/test/fixtures/vcr_cassettes/profile_draft_query.yml +++ b/test/fixtures/vcr_cassettes/profile_draft_query.yml @@ -3116,4 +3116,69 @@ http_interactions: http_version: recorded_at: Wed, 26 Jun 2019 00:00:17 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/profile_query.yml b/test/fixtures/vcr_cassettes/profile_query.yml index c3e47fc4e..2efeb8697 100644 --- a/test/fixtures/vcr_cassettes/profile_query.yml +++ b/test/fixtures/vcr_cassettes/profile_query.yml @@ -3116,4 +3116,69 @@ http_interactions: http_version: recorded_at: Wed, 26 Jun 2019 00:00:14 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/release_query.yml b/test/fixtures/vcr_cassettes/release_query.yml index bce98e6ba..5310b6c97 100644 --- a/test/fixtures/vcr_cassettes/release_query.yml +++ b/test/fixtures/vcr_cassettes/release_query.yml @@ -21139,4 +21139,69 @@ http_interactions: \ \n\n" http_version: recorded_at: Wed, 26 Jun 2019 00:00:20 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/unsupported_QDM_data_element.yml b/test/fixtures/vcr_cassettes/unsupported_QDM_data_element.yml index 058b60cfb..20a4f4bbc 100644 --- a/test/fixtures/vcr_cassettes/unsupported_QDM_data_element.yml +++ b/test/fixtures/vcr_cassettes/unsupported_QDM_data_element.yml @@ -2346,4 +2346,69 @@ http_interactions: http_version: recorded_at: Tue, 16 Jul 2019 11:59:25 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/update_response.yml b/test/fixtures/vcr_cassettes/update_response.yml index 99ee5fccc..7aabed41b 100644 --- a/test/fixtures/vcr_cassettes/update_response.yml +++ b/test/fixtures/vcr_cassettes/update_response.yml @@ -3067,4 +3067,69 @@ http_interactions: http_version: recorded_at: Wed, 07 Aug 2019 15:54:27 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/upload_measure_virus_200_infected_false.yml b/test/fixtures/vcr_cassettes/upload_measure_virus_200_infected_false.yml index efe37879f..922477e6f 100644 --- a/test/fixtures/vcr_cassettes/upload_measure_virus_200_infected_false.yml +++ b/test/fixtures/vcr_cassettes/upload_measure_virus_200_infected_false.yml @@ -1817,4 +1817,69 @@ http_interactions: recorded_at: Mon, 22 Mar 2021 15:38:23 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 6.0.0 diff --git a/test/fixtures/vcr_cassettes/valid_vsac_response.yml b/test/fixtures/vcr_cassettes/valid_vsac_response.yml index 3448c67dc..f2feb9b61 100644 --- a/test/fixtures/vcr_cassettes/valid_vsac_response.yml +++ b/test/fixtures/vcr_cassettes/valid_vsac_response.yml @@ -1762,4 +1762,69 @@ http_interactions: http_version: recorded_at: Tue, 16 Jul 2019 11:59:08 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/valid_vsac_response_Test169.yml b/test/fixtures/vcr_cassettes/valid_vsac_response_Test169.yml index 41283f97c..77840f120 100644 --- a/test/fixtures/vcr_cassettes/valid_vsac_response_Test169.yml +++ b/test/fixtures/vcr_cassettes/valid_vsac_response_Test169.yml @@ -2181,4 +2181,69 @@ http_interactions: http_version: recorded_at: Tue, 16 Jul 2019 11:59:06 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/valid_vsac_response_composite.yml b/test/fixtures/vcr_cassettes/valid_vsac_response_composite.yml index a370bdbd3..22af76374 100644 --- a/test/fixtures/vcr_cassettes/valid_vsac_response_composite.yml +++ b/test/fixtures/vcr_cassettes/valid_vsac_response_composite.yml @@ -7061,4 +7061,69 @@ http_interactions: http_version: recorded_at: Tue, 16 Jul 2019 12:00:33 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 25 Jun 2019 22:14:54 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/valid_vsac_response_hqmf_set_id_mismatch.yml b/test/fixtures/vcr_cassettes/valid_vsac_response_hqmf_set_id_mismatch.yml index 7a63c83fc..d1fbe0937 100644 --- a/test/fixtures/vcr_cassettes/valid_vsac_response_hqmf_set_id_mismatch.yml +++ b/test/fixtures/vcr_cassettes/valid_vsac_response_hqmf_set_id_mismatch.yml @@ -6183,4 +6183,69 @@ http_interactions: http_version: recorded_at: Wed, 07 Aug 2019 16:54:03 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/valid_vsac_response_reload_measure.yml b/test/fixtures/vcr_cassettes/valid_vsac_response_reload_measure.yml index f09db34e6..40f435300 100644 --- a/test/fixtures/vcr_cassettes/valid_vsac_response_reload_measure.yml +++ b/test/fixtures/vcr_cassettes/valid_vsac_response_reload_measure.yml @@ -3475,4 +3475,69 @@ http_interactions: http_version: recorded_at: Wed, 31 Jul 2019 17:39:21 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/vsac_500_response.yml b/test/fixtures/vcr_cassettes/vsac_500_response.yml index d79b03472..a0f00543e 100644 --- a/test/fixtures/vcr_cassettes/vsac_500_response.yml +++ b/test/fixtures/vcr_cassettes/vsac_500_response.yml @@ -1105,4 +1105,69 @@ http_interactions: http_version: recorded_at: Tue, 16 Jul 2019 11:59:22 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/fixtures/vcr_cassettes/vsac_not_found.yml b/test/fixtures/vcr_cassettes/vsac_not_found.yml index 9b8d89413..3b2552444 100644 --- a/test/fixtures/vcr_cassettes/vsac_not_found.yml +++ b/test/fixtures/vcr_cassettes/vsac_not_found.yml @@ -1049,4 +1049,69 @@ http_interactions: http_version: recorded_at: Wed, 26 Jun 2019 01:21:58 GMT +- request: + method: get + uri: https://vsac.nlm.nih.gov/vsac/svs/RetrieveMultipleValueSets?id=2.16.840.1.113762.1.4.1 + body: + encoding: US-ASCII + string: '' + headers: + User-Agent: + - Typhoeus - https://github.com/typhoeus/typhoeus + Expect: + - '' + response: + status: + code: 200 + message: '' + headers: + X-Frame-Options: + - SAMEORIGIN + X-Content-Type-Options: + - nosniff + - nosniff + X-Xss-Protection: + - 1; mode=block + Set-Cookie: + - BIGipServervsacweb_p=!SCfgAQec5rtpF53m9OGvBt4MxRMcjpPlF/OuKH6AP/UAcrxZqmT+h1oj21hM/AuyPQVjDWi/tpO9GEM=; + expires=Wed, 26-Jun-2019 00:14:54 GMT; path=/; Httponly; Secure + - JSESSIONID=0F17A9C8FEA88C36CB0D90F7B68A0BE0; Path=/vsac; HttpOnly;Secure + Cache-Control: + - no-cache, no-store, max-age=0, must-revalidate + Pragma: + - no-cache + Expires: + - '0' + Content-Type: + - text/xml;charset=utf-8 + Content-Length: + - '1356' + Date: + - Tue, 25 Jun 2019 22:14:53 GMT + X-Vip-Info: + - 130.14.16.40:443 + X-Pool-Info: + - "/Common/vsacweb_p 10.1.5.114 8080" + Strict-Transport-Security: + - max-age=31536000; includeSubDomains; preload + body: + encoding: UTF-8 + string: | + + + + + + + + Office of the National Coordinator for Health Information Technology + (Clinical Focus: Gender identity restricted to only Male and Female used in administrative situations requiring a restriction to these two categories.),(Data Element Scope: Gender),(Inclusion Criteria: Male and Female only.),(Exclusion Criteria: Any gender identity that is not male or female.) + Extensional + Dynamic + Active + 2019-06-25 + + + http_version: + recorded_at: Tue, 16 Jul 2019 11:59:42 GMT recorded_with: VCR 4.0.0 diff --git a/test/functional/api_v1/measures_controller_test.rb b/test/functional/api_v1/measures_controller_test.rb index 837b8ea5f..4f23763d8 100644 --- a/test/functional/api_v1/measures_controller_test.rb +++ b/test/functional/api_v1/measures_controller_test.rb @@ -86,7 +86,7 @@ class MeasuresControllerTest < ActionController::TestCase test 'should return bad_request when measure_file is not a file' do @request.env['CONTENT_TYPE'] = 'multipart/form-data' - post :create, params: {measure_file: 'not-a-file.gif', calculation_type: 'episode', vsac_tgt: 'foo', vsac_tgt_expires_at: @ticket_expires_at, vsac_query_type: 'profile'} + post :create, params: {measure_file: 'not-a-file.gif', calculation_type: 'episode', vsac_api_key: 'oof', vsac_query_type: 'profile'} assert_response :bad_request expected_response = { 'status' => 'error', 'messages' => "Invalid parameter 'measure_file': Must be a valid MAT Export." } assert_equal expected_response, JSON.parse(response.body) @@ -95,7 +95,7 @@ class MeasuresControllerTest < ActionController::TestCase test 'should return bad_request when measure_file is not a zip' do @request.env['CONTENT_TYPE'] = 'multipart/form-data' not_zip_file = fixture_file_upload(File.join('test','fixtures','measures','CMS160v6','cqm_measures','CMS160v6.json')) - post :create, params: {measure_file: not_zip_file, calculation_type: 'episode', vsac_tgt: 'foo', vsac_tgt_expires_at: @ticket_expires_at, vsac_query_type: 'profile'} + post :create, params: {measure_file: not_zip_file, calculation_type: 'episode', vsac_api_key: 'oof', vsac_query_type: 'profile'} assert_response :bad_request expected_response = { 'status' => 'error', 'messages' => "Invalid parameter 'measure_file': Must be a valid MAT Export." } assert_equal expected_response, JSON.parse(response.body) @@ -104,7 +104,7 @@ class MeasuresControllerTest < ActionController::TestCase test 'should return bad_request when the measure zip is not a MAT Export' do measure_file = fixture_file_upload(File.join('test','fixtures','cql_measure_exports','special_measures','not_mat_export.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' - post :create, params: {measure_file: measure_file, calculation_type: 'episode', vsac_tgt: 'foo', vsac_tgt_expires_at: @ticket_expires_at, vsac_query_type: 'profile'} + post :create, params: {measure_file: measure_file, calculation_type: 'episode', vsac_api_key: 'oof', vsac_query_type: 'profile'} assert_response :bad_request expected_response = { 'status' => 'error', 'messages' => "Invalid parameter 'measure_file': Must be a valid MAT Export." } assert_equal expected_response, JSON.parse(response.body) @@ -113,7 +113,7 @@ class MeasuresControllerTest < ActionController::TestCase test 'should return bad_request when calculation_type is invalid' do measure_file = fixture_file_upload(File.join('test','fixtures','cql_measure_exports','CMS52_v5_4_Artifacts.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' - post :create, params: {measure_file: measure_file, calculation_type: 'addition', vsac_tgt: 'foo', vsac_tgt_expires_at: @ticket_expires_at, vsac_query_type: 'profile'} + post :create, params: {measure_file: measure_file, calculation_type: 'addition', vsac_api_key: 'oof', vsac_query_type: 'profile'} assert_response :bad_request expected_response = { 'status' => 'error', 'messages' => "Invalid parameter 'calculation_type': Must be one of: episode, patient." } assert_equal expected_response, JSON.parse(response.body) @@ -136,10 +136,7 @@ class MeasuresControllerTest < ActionController::TestCase assert_nil measure VCR.use_cassette('api_valid_vsac_response', @vcr_options) do - # get ticket_granting_ticket - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'patient'} + post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'patient'} assert_response :success expected_response = { 'status' => 'success', 'url' => '/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076'} assert_equal expected_response, JSON.parse(response.body) @@ -159,14 +156,14 @@ class MeasuresControllerTest < ActionController::TestCase @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_valid_vsac_response_dup_measure', @vcr_options) do # get ticket_granting_ticket - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'patient'} + + + post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'patient'} assert_response :success expected_response = { 'status' => 'success', 'url' => '/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076'} assert_equal expected_response, JSON.parse(response.body) - post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'patient'} + post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'patient'} assert_response :conflict expected_response = { 'status' => 'error', 'messages' => 'A measure with this HQMF Set ID already exists.', 'url' => '/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076'} assert_equal expected_response, JSON.parse(response.body) @@ -178,9 +175,9 @@ class MeasuresControllerTest < ActionController::TestCase @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_valid_vsac_response_def_titles', @vcr_options) do # get ticket_granting_ticket - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'patient'} + + + post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'patient'} assert_response :ok expected_response = { 'status' => 'success', 'url' => '/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076'} assert_equal expected_response, JSON.parse(response.body) @@ -201,9 +198,9 @@ class MeasuresControllerTest < ActionController::TestCase @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_valid_vsac_response_provided_titles', @vcr_options) do # get ticket_granting_ticket - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'episode', population_titles: ['First Pop', 'First Strat', 'Second Strat', 'Third Strat']} + + + post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'episode', population_titles: ['First Pop', 'First Strat', 'Second Strat', 'Third Strat']} assert_response :ok expected_response = { 'status' => 'success', 'url' => '/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076'} assert_equal expected_response, JSON.parse(response.body) @@ -223,9 +220,9 @@ class MeasuresControllerTest < ActionController::TestCase @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_valid_vsac_response_initial', @vcr_options) do # get ticket_granting_ticket - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'episode', population_titles: ['First Pop', 'First Strat', 'Second Strat', 'Third Strat']} + + + post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'episode', population_titles: ['First Pop', 'First Strat', 'Second Strat', 'Third Strat']} assert_response :ok expected_response = { 'status' => 'success', 'url' => '/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076'} assert_equal expected_response, JSON.parse(response.body) @@ -243,10 +240,7 @@ class MeasuresControllerTest < ActionController::TestCase # Update the same measure VCR.use_cassette('api_valid_vsac_response_update', @vcr_options) do - # get ticket_granting_ticket - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - put :update, params: {id: '4DC3E7AA-8777-4749-A1E4-37E942036076', vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file1, calculation_type: 'episode', population_titles: %w[Foo bar baz bam]} + put :update, params: {id: '4DC3E7AA-8777-4749-A1E4-37E942036076', vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file1, calculation_type: 'episode', population_titles: %w[Foo bar baz bam]} assert_response :ok expected_response = { 'status' => 'success', 'url' => '/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076' } assert_equal expected_response, JSON.parse(response.body) @@ -264,23 +258,11 @@ class MeasuresControllerTest < ActionController::TestCase measure_file = fixture_file_upload(File.join('test','fixtures','cqm_measure_exports','CMS903v0.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_invalid_release_vsac_response', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_type: 'release', vsac_query_release: 'Fake 1234', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'episode'} - assert_response :bad_request - expected_response = {'status'=>'error', 'messages'=>'VSAC value set (2.16.840.1.113883.3.117.1.7.1.87) not found or is empty. Please verify that you are using the correct profile or release and have VSAC authoring permissions if you are requesting draft value sets.'} - assert_equal expected_response, JSON.parse(response.body) - end - end - test 'should error on upload due to invalid VSAC ticket' do - measure_file = fixture_file_upload(File.join('test','fixtures','cqm_measure_exports','CMS903v0.zip'),'application/zip') - @request.env['CONTENT_TYPE'] = 'multipart/form-data' - VCR.use_cassette('api_invalid_ticket_vsac_response', @vcr_options) do - ticket = 'foo' - post :create, params: {vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'episode'} + + post :create, params: {vsac_query_type: 'release', vsac_query_release: 'Fake 1234', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'episode'} assert_response :bad_request - expected_response = {'status'=>'error', 'messages'=>'VSAC session expired. Please try again.'} + expected_response = {'status'=>'error', 'messages'=>'VSAC value set (2.16.840.1.113883.3.117.1.7.1.87) not found or is empty. Please verify that you are using the correct profile or release and have VSAC authoring permissions if you are requesting draft value sets.'} assert_equal expected_response, JSON.parse(response.body) end end @@ -289,9 +271,9 @@ class MeasuresControllerTest < ActionController::TestCase measure_file = fixture_file_upload(File.join('test','fixtures','cql_measure_exports','IETCQL_v5_0_missing_vs_oid_Artifacts.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_missing_vs_vsac_response', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'episode'} + + + post :create, params: {vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'episode'} assert_response :bad_request expected_response = {'status'=>'error', 'messages'=>'Measure loading process encountered error: The HQMF file references the following valuesets not present in the CQL: ["2.16.840.1.113883.3.464.1003.106.12.1005"]'} assert_equal expected_response, JSON.parse(response.body) @@ -302,9 +284,9 @@ class MeasuresControllerTest < ActionController::TestCase measure_update_file = fixture_file_upload(File.join('test','fixtures','cql_measure_exports','IETCQL_v5_0_Artifacts.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_valid_vsac_response_non_exist_measure', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - put :update, params: {id: '762B1B52-40BF-4596-B34F-4963188E7FF7', vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_update_file, calculation_type: 'episode'} + + + put :update, params: {id: '762B1B52-40BF-4596-B34F-4963188E7FF7', vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_update_file, calculation_type: 'episode'} assert_response :not_found expected_response = { 'status' => 'error', 'messages' => 'No measure found for this HQMF Set ID.'} assert_equal expected_response, JSON.parse(response.body) @@ -317,16 +299,14 @@ class MeasuresControllerTest < ActionController::TestCase measure_file = fixture_file_upload(File.join('test','fixtures','cqm_measure_exports','CMS903v0.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_incorrect_hqmf_id_vsac_response', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {measure_file: measure_file, calculation_type: 'episode', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at} + post :create, params: {measure_file: measure_file, calculation_type: 'episode', vsac_api_key: ENV['VSAC_API_KEY']} assert_response :success expected_response = { 'status' => 'success', 'url' => '/api_v1/measures/4DC3E7AA-8777-4749-A1E4-37E942036076'} assert_equal expected_response, JSON.parse(response.body) measure_update_file = fixture_file_upload(File.join('test','fixtures','cqm_measure_exports','CMS903v0_mismatch_hqmf_set_id.zip'),'application/zip') - put :update, params: {id: '4DC3E7AA-8777-4749-A1E4-37E942036076', measure_file: measure_update_file, calculation_type: 'episode', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at} + put :update, params: {id: '4DC3E7AA-8777-4749-A1E4-37E942036076', measure_file: measure_update_file, calculation_type: 'episode', vsac_api_key: ENV['VSAC_API_KEY']} assert_response :not_found expected_response = { 'status' => 'error', 'messages' => 'The update file does not have a matching HQMF Set ID to the measure trying to update with. Please update the correct measure or upload the file as a new measure.'} assert_equal expected_response, JSON.parse(response.body) @@ -337,9 +317,7 @@ class MeasuresControllerTest < ActionController::TestCase measure_file = fixture_file_upload(File.join('test','fixtures','cql_measure_exports','IETCQL_v5_0_bad_hqmf_Artifacts.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_incorrect_hqmf_vsac_response', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {measure_file: measure_file, calculation_type: 'episode', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at} + post :create, params: {measure_file: measure_file, calculation_type: 'episode', vsac_api_key: ENV['VSAC_API_KEY']} assert_response :internal_server_error expected_response = {'status'=>'error', 'messages'=>'The measure could not be loaded, Bonnie has encountered an error while trying to load the measure.'} assert_equal expected_response, JSON.parse(response.body) @@ -350,9 +328,7 @@ class MeasuresControllerTest < ActionController::TestCase measure_file = fixture_file_upload(File.join('test','fixtures','cql_measure_exports', 'CCDELookback_v5_4_Artifacts.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_ccdelookback_vsac_response', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_measure_defined: 'false', vsac_query_include_draft: 'false', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'episode', calculate_sdes: 'true'} + post :create, params: {vsac_query_measure_defined: 'false', vsac_query_include_draft: 'false', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'episode', calculate_sdes: 'true'} assert_response :success measure = CQM::Measure.where({hqmf_set_id: 'FA75DE85-A934-45D7-A2F7-C700A756078B'}).first assert_equal true, measure.calculate_sdes @@ -363,9 +339,7 @@ class MeasuresControllerTest < ActionController::TestCase measure_file = fixture_file_upload(File.join('test','fixtures','cql_measure_exports', 'CCDELookback_v5_4_Artifacts.zip'),'application/zip') @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('api_release_ccdelookback_vsac_response', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] - post :create, params: {vsac_query_type: 'release', vsac_query_measure_defined: 'true', vsac_tgt: ticket, vsac_tgt_expires_at: @ticket_expires_at, measure_file: measure_file, calculation_type: 'episode', calculate_sdes: 'false'} + post :create, params: {vsac_query_type: 'release', vsac_query_measure_defined: 'true', vsac_api_key: ENV['VSAC_API_KEY'], measure_file: measure_file, calculation_type: 'episode', calculate_sdes: 'false'} assert_response :success measure = CQM::Measure.where({hqmf_set_id: 'FA75DE85-A934-45D7-A2F7-C700A756078B'}).first assert_equal false, measure.calculate_sdes @@ -388,8 +362,7 @@ class MeasuresControllerTest < ActionController::TestCase @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('valid_vsac_response_composite_api_initial', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] + post :create, params: { vsac_query_type: 'profile', vsac_query_profile: 'eCQM Update 2020-05-07', @@ -412,8 +385,7 @@ class MeasuresControllerTest < ActionController::TestCase @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('valid_vsac_response_composite_api_again', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] + post :update, params: { vsac_query_type: 'profile', id: '244B4F52-C9CA-45AA-8BDB-2F005DA05BFC', @@ -443,8 +415,7 @@ class << measure_file end @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('valid_vsac_response_bad_composite_api', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] + post :create, params: { vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', @@ -452,8 +423,7 @@ class << measure_file vsac_query_measure_defined: 'true', measure_file: measure_file, calculation_type: 'patient', - vsac_tgt: ticket, - vsac_tgt_expires_at: @ticket_expires_at + vsac_api_key: ENV['VSAC_API_KEY'] } end @@ -469,8 +439,7 @@ class << measure_file end @request.env['CONTENT_TYPE'] = 'multipart/form-data' VCR.use_cassette('valid_vsac_response_bad_composite_api', @vcr_options) do - api = Util::VSAC::VSACAPI.new(config: APP_CONFIG['vsac'], api_key: ENV['VSAC_API_KEY']) - ticket = api.ticket_granting_ticket[:ticket] + post :create, params: { vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', @@ -478,8 +447,7 @@ class << measure_file vsac_query_measure_defined: 'true', measure_file: measure_file, calculation_type: 'patient', - vsac_tgt: ticket, - vsac_tgt_expires_at: @ticket_expires_at + vsac_api_key: ENV['VSAC_API_KEY'] } end assert_response :bad_request diff --git a/test/functional/measures_controller_test.rb b/test/functional/measures_controller_test.rb index 6cd0c5d82..34160a156 100644 --- a/test/functional/measures_controller_test.rb +++ b/test/functional/measures_controller_test.rb @@ -457,7 +457,7 @@ class << measure_file end test 'measure destroy' do - VCR.use_cassette('measure_destroy', @vcr_options) do + VCR.use_cassette('measure_destroy', {match_requests_on: [:method, :uri_no_st], :allow_playback_repeats => true}) do measure_file1 = fixture_file_upload(File.join('test', 'fixtures', 'cqm_measure_exports', 'CMS903v0.zip'), 'application/zip') measure_file2 = fixture_file_upload(File.join('test', 'fixtures', 'cqm_measure_exports', 'CMS134v8.zip'), 'application/zip') @@ -501,7 +501,7 @@ class << measure_file attr_reader :tempfile end # give it a fake VSAC ticket to get through the check for one - session[:vsac_tgt] = { ticket: 'fake ticket', expires: DateTime.now + 60.minutes } + session[:vsac_api_key] = "somethingNeat" post :create, params: {measure_file: measure_file, measure_type: 'eh', calculation_type: 'episode'} assert_equal 'Error Uploading Measure', flash[:error][:title] assert_equal 'The uploaded zip file is not a valid Measure Authoring Tool (MAT) export of a CQL Based Measure.', flash[:error][:summary] @@ -515,7 +515,7 @@ class << measure_file attr_reader :tempfile end # give it a fake VSAC ticket to get through the check for one - session[:vsac_tgt] = { ticket: 'fake ticket', expires: DateTime.now + 60.minutes } + session[:vsac_api_key] = "somethingNeat" post :create, params: {measure_file: measure_file, measure_type: 'eh', calculation_type: 'episode', vsac_api_key: ENV['VSAC_API_KEY']} assert_equal 'Error Uploading Measure', flash[:error][:title] assert_equal 'The uploaded zip file is not a valid Measure Authoring Tool (MAT) export of a CQL Based Measure.', flash[:error][:summary] @@ -529,8 +529,8 @@ class << measure_file class << measure_file attr_reader :tempfile end - # give it a fake VSAC ticket to get through the check for one - session[:vsac_tgt] = { ticket: 'fake ticket', expires: DateTime.now + 60.minutes } + # give it a fake VSAC key to get through the check for one + session[:vsac_api_key] = "somethingNeat" post :create, params: {measure_file: measure_file, measure_type: 'eh', calculation_type: 'episode'} assert_response :redirect @@ -555,7 +555,7 @@ class << measure_file test 'upload measure already loaded' do measure = nil # Use the valid vsac response recording each time attempting to upload measure - VCR.use_cassette('valid_vsac_response_reload_measure', @vcr_options) do + VCR.use_cassette('valid_vsac_response_reload_measure', {match_requests_on: [:method, :uri_no_st], :allow_playback_repeats => true}) do sign_in @user measure_file = fixture_file_upload(File.join('test', 'fixtures', 'cql_measure_exports', 'core_measures', 'CMS158v6_bonnie-fixtures@mitre.org_2018-01-11.zip'), 'application/zip') class << measure_file @@ -635,7 +635,7 @@ class << measure_file test 'update with hqmf set id mismatch' do # Upload the initial file - VCR.use_cassette('valid_vsac_response_hqmf_set_id_mismatch', @vcr_options) do + VCR.use_cassette('valid_vsac_response_hqmf_set_id_mismatch', {match_requests_on: [:method, :uri_no_st], :allow_playback_repeats => true}) do measure_file = fixture_file_upload(File.join('test', 'fixtures', 'cqm_measure_exports', 'CMS903v0.zip'), 'application/zip') class << measure_file attr_reader :tempfile @@ -825,7 +825,7 @@ class << measure_file assert_equal false, measure.calculation_method == 'EPISODE_OF_CARE' - VCR.use_cassette('valid_vsac_response', @vcr_options) do + VCR.use_cassette('valid_vsac_response', {match_requests_on: [:method, :uri_no_st], :allow_playback_repeats => true}) do post :create, params: { vsac_query_type: 'profile', vsac_query_profile: 'Latest eCQM', diff --git a/test/functional/vsac_util_controller_test.rb b/test/functional/vsac_util_controller_test.rb index 542b63145..6bf299d58 100644 --- a/test/functional/vsac_util_controller_test.rb +++ b/test/functional/vsac_util_controller_test.rb @@ -53,38 +53,11 @@ class VsacUtilControllerTest < ActionController::TestCase end test "vsac auth valid" do - # The ticket field was taken from the vcr_cassettes/valid_vsac_response file - session[:vsac_tgt] = {ticket: "ST-67360-HgEfelIvwUQ3zz3X39fg-cas", expires: Time.now.utc + 27000} - get :auth_valid - - assert_response :ok - assert_equal true, JSON.parse(response.body)['valid'] - end - - test "vsac auth invalid" do - # Time is past expired - # The ticket field was taken from the vcr_cassettes/valid_vsac_response file - session[:vsac_tgt] = {ticket: "ST-67360-HgEfelIvwUQ3zz3X39fg-cas", expires: Time.now.utc - 27000} - get :auth_valid - - assert_response :ok - assert_equal false, JSON.parse(response.body)['valid'] - end - - test "force expire vsac session" do - # The ticket field was taken from the vcr_cassettes/valid_vsac_response file - session[:vsac_tgt] = {ticket: "ST-67360-HgEfelIvwUQ3zz3X39fg-cas", expires: Time.now.utc + 27000} - post :auth_expire - - assert_response :ok - assert_equal "{}", response.body - - assert_nil session[:vsac_tgt] - - # Assert that vsac_auth_valid returns that vsac session is invalid - get :auth_valid - - assert_response :ok - assert_equal false, JSON.parse(response.body)['valid'] + session[:vsac_api_key] = "somethingNeat" + VCR.use_cassette('api_valid_vsac_response') do + get :auth_valid + assert_response :ok + assert_equal true, JSON.parse(response.body)['valid'] + end end end