Skip to main content Link Search Menu Expand Document (external link)

Getting Started

Table of Contents

  1. Getting Started for Inferno Users
    1. A Single Test Kit
    2. Multiple Test Kits
  2. Getting Started for Inferno Test Writers
    1. Installation
    2. Running Inferno
    3. Next Steps

Getting Started for Inferno Users

Start here if you’re interested in testing a FHIR server against one or more existing Test Kits.

A Single Test Kit

Most Test Kits are developed using the Inferno Template repository which provides scripts for standing up an instance of Inferno to run a selected Test Kit.

e.g. the US Core Test Kit

git clone https://github.com/inferno-framework/us-core-test-kit.git
./setup.sh
./run.sh

Always check the documentation for an individual Test Kit since they may differ from this standard approach.

Multiple Test Kits

There may be times when you wish to offer multiple test kits in a single Inferno instance. There may be times when you wish to run multiple, different Test Kits through a single Inferno instance. You can load and run two or more separate Test Kits by using Inferno Template.

To create and deploy a custom combination of Test Kits with the Inferno Template first create a new repository based off the template or clone the template:

git clone https://github.com/inferno-framework/inferno-template.git

Add Test Kits you want to include to the Gemfile:

gem 'smart_app_launch_test_kit',
    git: 'https://github.com/inferno-framework/smart-app-launch-test-kit.git',
    branch: 'main'
gem 'us_core_test_kit',
    git: 'https://github.com/inferno-framework/us-core-test-kit.git',
    branch: 'main'

To enable the Test Kits, require them in in lib/inferno_template.rb:

require 'smart_app_launch_test_kit'
require 'us_core_test_kit'

Inferno relies on external validation services for profile validation; by default, Inferno uses the FHIR Validator Wrapper. For Test Kits that require profile validation, such as the US Core Test Kit, the corresponding Implementation Guide will need to be placed in the lib/inferno_deployment/igs/ directory as a .tgz file (i.e. package.tgz). The Implementation Guide files for a Test Kit can be located in that kit’s git repository and just copied over directly:

e.g. for the US Core Test Kit

git clone https://github.com/inferno-framework/us-core-test-kit.git
cp -a /us-core-test-kit/lib/us_core/igs/. /inferno_template/lib/inferno_template/igs/

Once this is done you can build and run the instance:

./setup.sh
./run.sh

Note: Example Test Suites, Groups, Tests and IGs in the template can be removed.

Getting Started for Inferno Test Writers

Installation

  1. Install Docker.
  2. Clone the Inferno Template repository. You can either clone this repository directly, or click the green “Use this template” button to create your own repository based on this one.
  3. Run ./setup.sh in the template repository to retrieve the necessary docker images and create a database.

Running Inferno

After installation, run the ./run.sh script to start Inferno.

  • Navigate to localhost to access Inferno and run test suites.
  • Navigate to localhost/validator to access a standalone validator that can be used to validate individual FHIR resources.

Next Steps

Now that Inferno is running, you could learn about the file/directory organization or just start writing tests.