SlideShare a Scribd company logo
FHIR® is the registered trademark of HL7 and is used with the permission of HL7. The Flame Design mark is the registered trademark of HL7 and is used with the permission of HL7.
Amsterdam, 15-17 November | @fhir_furore | #fhirdevdays17 | www.fhirdevdays.com
Test Driven Development II - Advanced
Richard Ettema, AEGIS.net, Inc.
Presented by
• Name: Richard Ettema
• Position:
• Lead Consultant, AEGIS.net, Inc.
• FHIR® Certified Implementer
• Background:
• 34+ years IT industry experience
• 14+ years leading HIT development/implementation efforts
• 4+ years contributing to the HL7® FHIR® specification (focus on testing)
• Sr. Architect / Lead Developer for the Touchstone Project
• Author of the AEGIS WildFHIR public test server and client
Test Driven Development with FHIR
Intro Session Review
• To ensure interoperability between applications claiming
conformance to the specification, a testing framework has been
established within the FHIR specification itself
https://www.hl7.org/fhir/STU3/testing.html
• This framework defines a Test Engine for processing a TestScript
resource as a natural language, computable format of a test case
• The TestScript resource is an implementation-agnostic description of
tests that allows test engines to evaluate if a FHIR implementation
conforms with the FHIR specification
https://www.hl7.org/fhir/STU3/testscript.html
• Testing workflow example
• How can we trust that the correction is being tested in the same way?
Can we trust either test outcome?
Known data facilitates known, expected outcomes
We will review and examine how to ensure “Reliable and Repeatable Testing”
during the Hands-on Exercises using a “Two Users, Same Data” scenario
Test Passes
Run Test
Again
Developer
Correction
Test FailsRun Test
Reliable and Repeatable Testing
Identifying Your Testing Criteria; a.k.a. Asserts
• Testing simple values
• Is this the patient I expected?
• Is this the operation response I expected?
• Did I get multiple matches when I expected one?
• Testing specification conformance
• Is this element required?
• Is this code value correct?
• Testing conditionality or constraints
• Can this element be expressed more than one way and still be compliant?
• Is this element is only required when another element is present?
Asserts can perform…
• simple operations
• standard assert operators are constrained to the following: equals |
notEquals | in | notIn | greaterThan | lessThan | empty | notEmpty |
contains | notContains | eval
• specification allows for use of XPath or JSONPath expressions
• complex evaluations
• specification allows for rules to be defined within the assert
• specification allows for use of FHIRPath* expressions
*FHIRPath is supported within the TestScript resource and by the Touchstone test engine, but will not be a
focus of this session. To learn more about FHIRPath, see http://hl7.org/fhirpath
Complex Asserts
• Are used when testing conditionality, constraints or simplifying an
existing test construct
• Support the use of FHIRPath
• FHIRPath has expressions, functions, operations
• Far more functionality than found in the simple assert operators
• Built-in expressions such as dateTime and quantity
• Expressions can contain operators
• Functions like isDistinct, count, subsetOf, supersetOf
• Support Rules and Rulesets (high level language scripted logic)
• Touchstone Rules Engine supports Groovy, Schematron and XSLT
Complex Asserts - FHIRPath Example
• FHIRPath provides a syntax neutral way to access the contents of a
resource and can simplify assert logic constructs
Assert condition:
“Confirm that the searchset Bundle total number of entries is at least
one (1).”
• Let’s compare XPath and JSONPath to FHIRPath…
Complex Asserts - FHIRPath Example
Comparison with XPath and JSONPath
• XPath assert
<assert>
<operation value=“greaterThan” />
<path value=“/Bundle/total” />
<value value=“0” />
</assert>
• JSONPath assert
<assert>
<operation value=“greaterThan” />
<path value=“.total” />
<value value=“0” />
</assert>
• FHIRPath assert (equivalent logic)
<assert>
<expression value=“Bundle.total.toInteger() &gt; 0” />
</assert>
• FHIRPath assert (alternative logic)
<assert>
<expression value=“Bundle.entry.count() &gt; 0” />
</assert>
Complex Asserts - Rules and Rulesets
• The TestScript resource allows the use of Rules and Rulesets within
the assert
• Rules are called during TestScript execution
• In Touchstone, the Rules are hosted within the Test Definition folders
• Rules may be viewed and will be displayed in Test Results if selected
• Rulesets are simply collections of one or more Rules
• Allows for the definition of a group of Rules to be referenced within the
TestScript in an efficient manner
We will review and examine Rules and Rulesets during the Hands-on Exercises
FHIR Client or Peer-to-Peer Testing
• TestScripts in Touchstone can be either Server-only, Client (Peer-to-
Peer), or Multi-actor
• Server-only: Touchstone initiates requests to the destination FHIR System and
evaluates the response
• Client (Peer-to-Peer): Touchstone waits for a request from the origin FHIR
System to be received, evaluates the request, sends to the destination FHIR
System, and evaluates the response
• Multi-actor: Touchstone may act as the initiating system along with other
FHIR Test Systems acting as either a Client or Server
Client (Peer-to-Peer) Testing - Test Setup
• Select a Client TestScript from the
Test Definitions list
• Select and fill in any test data
necessary for test execution
• Origin Test System (Client)
• Destination Test System (Server)
• (Dynamic) Variables
Client (Peer-to-Peer) Testing - Test Execution
Client (Peer-to-Peer) Testing - TestScript Execution
We will review and examine Client Testing during the Hands-on Exercises
Captured Message Exchanges
• The Exchanges dashboard in Touchstone allows users to view all captured request
and response messages
• Touchstone will match an exchange with a test execution using these checks:
• If your test server is already defined within Touchstone and is publicly accessible, the message can be
matched by originating IP address
• If that is not possible, the system attempts to use USER_KEY and ORG_KEY
• Else, the system cannot match the message to a test execution
USER_KEY and ORG_KEY
• USER_KEY and ORG_KEY are
special placeholders
• They can be sent by the client
system as an HTTP request header
or within the request payload
• They identify the client system
when the machine name or IP
address would not
Introducing the Touchstone APIs
• Test executions can be launched and monitored via remote RESTful
web services
• Provides the means to integrate Touchstone into your organization’s
test executions for:
• Internal automated regressions tests
• Continuous Integration build processes
• Documentation and example messages are available
• Supported formats – JSON and XML
Touchstone API Capabilities
• The Touchstone APIs allow for many of the same non-administrative
functions as the User Interface
• Test executions launched on behalf of a remote test user via
Touchstone API will be visible to all members of your organization on
the Touchstone UI
• Any member of your organization can log in to the Touchstone UI and
investigate test failures if needed
Touchstone API Services
POST authenticate  Authenticate with Touchstone; return new API session key
POST testExecution  Launch a new test execution for an existing Test Setup
GET testExecution  Return the status of a know test execution
GET testExecDetail  Return summary status of all test execution TestScripts
GET scriptExecDetail  Return test execution single TestScript details
GET testReport  Same as GET scriptExecDetail except returns FHIR TestReport
Touchstone API - Jenkins CI Server Integration Example
• The Touchstone User Guide documents a Jenkins CI Server Integration
Example
• https://touchstone.aegis.net/touchstone/TouchstoneUserGuide, section
‘Touchstone API – Jenkins Integration Example’
• Illustrates the use of the Jenkins Groovy Plugin
• Builds on the example code from the previous ‘Touchstone API – Definition’
section
Due to not having a publicly available Jenkins CI Server at this event, there is no
corresponding Hands-on Exercises for this topic.
Conformance Testing
• Conformance Testing validates a system against known standards
• FHIR Specification (including Implementation Guides)
• Version support (forward/backward compatibility)
• Continuous Conformance Testing shows that an organization is
currently conformant, but also committed to remain conformant
• Future development minded - interoperability needs to be addressed on a
continuous basis
• Development Aid - developers can integrate FHIR conformance testing into
their build cycle to avoid costly conformance code rewrites later
• Regression testing - validate that changes and enhancements are also
conformant
Touchstone Conformance Analytics
Hands on Exercises
• Reliable and Repeatable Testing - Two Users, Same Data
• Complex Asserts
• FHIRPath comparison to XPath and JSONPath
• Rules and Rulesets
• Advanced TestScripts
• FHIR Client / Peer-to-Peer
• Conformance Analytics Dashboard
• Connectathon Test Track
• We will continue our review of one of the test tracks for the next HL7 FHIR
Connectathon 17 event and the development of TestScripts
Discussion (Q & A)
FHIR® is the registered trademark of HL7 and is used with the permission of HL7. The Flame Design mark is the registered trademark of HL7 and is used with the permission of HL7.
Amsterdam, 15-17 November | @fhir_furore | #fhirdevdays17 | www.fhirdevdays.com
Thank you!

More Related Content

What's hot

Furore devdays2017 general-introtofhir
Furore devdays2017 general-introtofhirFurore devdays2017 general-introtofhir
Furore devdays2017 general-introtofhir
DevDays
 
Profiling with clin fhir
Profiling with clin fhirProfiling with clin fhir
Profiling with clin fhir
DevDays
 
Furore devdays 2017- profiling academy - profiling guidelines v1
Furore devdays 2017- profiling academy - profiling guidelines v1Furore devdays 2017- profiling academy - profiling guidelines v1
Furore devdays 2017- profiling academy - profiling guidelines v1
DevDays
 
Fhir foundation (grahame)
Fhir foundation (grahame)Fhir foundation (grahame)
Fhir foundation (grahame)
DevDays
 
Dev days 2017 questionnaires (brian postlethwaite)
Dev days 2017 questionnaires (brian postlethwaite)Dev days 2017 questionnaires (brian postlethwaite)
Dev days 2017 questionnaires (brian postlethwaite)
DevDays
 
Furore devdays 2017-sdc (lloyd)
Furore devdays 2017-sdc (lloyd)Furore devdays 2017-sdc (lloyd)
Furore devdays 2017-sdc (lloyd)
DevDays
 
Fire kit ios (r-baldwin)
Fire kit ios (r-baldwin)Fire kit ios (r-baldwin)
Fire kit ios (r-baldwin)
DevDays
 
Fhir dev days_basic_fhir_terminology_services
Fhir dev days_basic_fhir_terminology_servicesFhir dev days_basic_fhir_terminology_services
Fhir dev days_basic_fhir_terminology_services
DevDays
 
Furore devdays 2017- rdf2(solbrig)
Furore devdays 2017- rdf2(solbrig)Furore devdays 2017- rdf2(solbrig)
Furore devdays 2017- rdf2(solbrig)
DevDays
 
Advanced .net api (ewout)
Advanced .net api (ewout)Advanced .net api (ewout)
Advanced .net api (ewout)
DevDays
 
Fhir tooling (grahame)
Fhir tooling (grahame)Fhir tooling (grahame)
Fhir tooling (grahame)
DevDays
 
20171116 rene spronk_profiling_governance
20171116 rene spronk_profiling_governance20171116 rene spronk_profiling_governance
20171116 rene spronk_profiling_governance
DevDays
 
Beginners .net api dev days2017
Beginners  .net api   dev days2017Beginners  .net api   dev days2017
Beginners .net api dev days2017
DevDays
 
Vonk fhir facade (christiaan)
Vonk fhir facade (christiaan)Vonk fhir facade (christiaan)
Vonk fhir facade (christiaan)
DevDays
 
Dev days 2017 advanced directories (brian postlethwaite)
Dev days 2017 advanced directories (brian postlethwaite)Dev days 2017 advanced directories (brian postlethwaite)
Dev days 2017 advanced directories (brian postlethwaite)
DevDays
 
final Keynote (grahame)
final Keynote (grahame)final Keynote (grahame)
final Keynote (grahame)
DevDays
 
Building a Scenario using clinFHIR
Building a Scenario using clinFHIRBuilding a Scenario using clinFHIR
Building a Scenario using clinFHIR
DevDays
 
Integrating with the epic platform fhir dev days 17
Integrating with the epic platform fhir dev days 17Integrating with the epic platform fhir dev days 17
Integrating with the epic platform fhir dev days 17
DevDays
 
Validation in net and java (ewout james)
Validation in net and java (ewout james)Validation in net and java (ewout james)
Validation in net and java (ewout james)
DevDays
 
Furore devdays 2017- rdf1(solbrig)
Furore devdays 2017- rdf1(solbrig)Furore devdays 2017- rdf1(solbrig)
Furore devdays 2017- rdf1(solbrig)
DevDays
 

What's hot (20)

Furore devdays2017 general-introtofhir
Furore devdays2017 general-introtofhirFurore devdays2017 general-introtofhir
Furore devdays2017 general-introtofhir
 
Profiling with clin fhir
Profiling with clin fhirProfiling with clin fhir
Profiling with clin fhir
 
Furore devdays 2017- profiling academy - profiling guidelines v1
Furore devdays 2017- profiling academy - profiling guidelines v1Furore devdays 2017- profiling academy - profiling guidelines v1
Furore devdays 2017- profiling academy - profiling guidelines v1
 
Fhir foundation (grahame)
Fhir foundation (grahame)Fhir foundation (grahame)
Fhir foundation (grahame)
 
Dev days 2017 questionnaires (brian postlethwaite)
Dev days 2017 questionnaires (brian postlethwaite)Dev days 2017 questionnaires (brian postlethwaite)
Dev days 2017 questionnaires (brian postlethwaite)
 
Furore devdays 2017-sdc (lloyd)
Furore devdays 2017-sdc (lloyd)Furore devdays 2017-sdc (lloyd)
Furore devdays 2017-sdc (lloyd)
 
Fire kit ios (r-baldwin)
Fire kit ios (r-baldwin)Fire kit ios (r-baldwin)
Fire kit ios (r-baldwin)
 
Fhir dev days_basic_fhir_terminology_services
Fhir dev days_basic_fhir_terminology_servicesFhir dev days_basic_fhir_terminology_services
Fhir dev days_basic_fhir_terminology_services
 
Furore devdays 2017- rdf2(solbrig)
Furore devdays 2017- rdf2(solbrig)Furore devdays 2017- rdf2(solbrig)
Furore devdays 2017- rdf2(solbrig)
 
Advanced .net api (ewout)
Advanced .net api (ewout)Advanced .net api (ewout)
Advanced .net api (ewout)
 
Fhir tooling (grahame)
Fhir tooling (grahame)Fhir tooling (grahame)
Fhir tooling (grahame)
 
20171116 rene spronk_profiling_governance
20171116 rene spronk_profiling_governance20171116 rene spronk_profiling_governance
20171116 rene spronk_profiling_governance
 
Beginners .net api dev days2017
Beginners  .net api   dev days2017Beginners  .net api   dev days2017
Beginners .net api dev days2017
 
Vonk fhir facade (christiaan)
Vonk fhir facade (christiaan)Vonk fhir facade (christiaan)
Vonk fhir facade (christiaan)
 
Dev days 2017 advanced directories (brian postlethwaite)
Dev days 2017 advanced directories (brian postlethwaite)Dev days 2017 advanced directories (brian postlethwaite)
Dev days 2017 advanced directories (brian postlethwaite)
 
final Keynote (grahame)
final Keynote (grahame)final Keynote (grahame)
final Keynote (grahame)
 
Building a Scenario using clinFHIR
Building a Scenario using clinFHIRBuilding a Scenario using clinFHIR
Building a Scenario using clinFHIR
 
Integrating with the epic platform fhir dev days 17
Integrating with the epic platform fhir dev days 17Integrating with the epic platform fhir dev days 17
Integrating with the epic platform fhir dev days 17
 
Validation in net and java (ewout james)
Validation in net and java (ewout james)Validation in net and java (ewout james)
Validation in net and java (ewout james)
 
Furore devdays 2017- rdf1(solbrig)
Furore devdays 2017- rdf1(solbrig)Furore devdays 2017- rdf1(solbrig)
Furore devdays 2017- rdf1(solbrig)
 

Similar to Furore devdays2017 tdd-2-advanced

Writing Acceptance Tests Using Fitnesse
Writing Acceptance Tests Using FitnesseWriting Acceptance Tests Using Fitnesse
Writing Acceptance Tests Using Fitnesse
Facundo Farias
 
Choosing right-automation-tool
Choosing right-automation-toolChoosing right-automation-tool
Choosing right-automation-tool
BabuDevanandam
 
Accelerate and Automate PeopleSoft 9.2/9.1 Testing with PeopleSoft Test Frame...
Accelerate and Automate PeopleSoft 9.2/9.1 Testing with PeopleSoft Test Frame...Accelerate and Automate PeopleSoft 9.2/9.1 Testing with PeopleSoft Test Frame...
Accelerate and Automate PeopleSoft 9.2/9.1 Testing with PeopleSoft Test Frame...
Arvind Rajan
 
KrishnaToolComparisionPPT.pdf
KrishnaToolComparisionPPT.pdfKrishnaToolComparisionPPT.pdf
KrishnaToolComparisionPPT.pdf
QA or the Highway
 
FUNTASY - Functional testing automated system
FUNTASY - Functional testing automated systemFUNTASY - Functional testing automated system
FUNTASY - Functional testing automated system
Qualitest
 
Beginners overview of automated testing with Rspec
Beginners overview of automated testing with RspecBeginners overview of automated testing with Rspec
Beginners overview of automated testing with Rspec
jeffrey1ross
 
Unit Testng with PHP Unit - A Step by Step Training
Unit Testng with PHP Unit - A Step by Step TrainingUnit Testng with PHP Unit - A Step by Step Training
Unit Testng with PHP Unit - A Step by Step Training
Ram Awadh Prasad, PMP
 
No Devops Without Continuous Testing
No Devops Without Continuous TestingNo Devops Without Continuous Testing
No Devops Without Continuous Testing
Parasoft
 
Test Automation using UiPath Test Suite - Developer Circle Part-3 - 07262022.pdf
Test Automation using UiPath Test Suite - Developer Circle Part-3 - 07262022.pdfTest Automation using UiPath Test Suite - Developer Circle Part-3 - 07262022.pdf
Test Automation using UiPath Test Suite - Developer Circle Part-3 - 07262022.pdf
Diana Gray, MBA
 
Best Practices in Web Service Design
Best Practices in Web Service DesignBest Practices in Web Service Design
Best Practices in Web Service Design
Lorna Mitchell
 
Testing, a pragmatic approach
Testing, a pragmatic approachTesting, a pragmatic approach
Testing, a pragmatic approach
Enrico Da Ros
 
Getting Started with Test-Driven Development at Longhorn PHP 2023
Getting Started with Test-Driven Development at Longhorn PHP 2023Getting Started with Test-Driven Development at Longhorn PHP 2023
Getting Started with Test-Driven Development at Longhorn PHP 2023
Scott Keck-Warren
 
Perforce Web Services
Perforce Web ServicesPerforce Web Services
Perforce Web Services
Perforce
 
Context Driven Automation Gtac 2008
Context Driven Automation Gtac 2008Context Driven Automation Gtac 2008
Context Driven Automation Gtac 2008
Pete Schneider
 
26.1a.Introduction to DEVOPS_v2.pptx
26.1a.Introduction to DEVOPS_v2.pptx26.1a.Introduction to DEVOPS_v2.pptx
26.1a.Introduction to DEVOPS_v2.pptx
Panos Fitsilis
 
Automated Developer Testing: Achievements and Challenges
Automated Developer Testing: Achievements and ChallengesAutomated Developer Testing: Achievements and Challenges
Automated Developer Testing: Achievements and Challenges
Tao Xie
 
Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Acceptance & Functional Testing with Codeception - SunshinePHP 2016Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Joe Ferguson
 
BDD for APIs
BDD for APIsBDD for APIs
BDD for APIs
Jason Harmon
 
Acceptance & Functional Testing with Codeception - Devspace 2015
Acceptance & Functional Testing with Codeception - Devspace 2015 Acceptance & Functional Testing with Codeception - Devspace 2015
Acceptance & Functional Testing with Codeception - Devspace 2015
Joe Ferguson
 
Learn software testing with tech partnerz 1
Learn software testing with tech partnerz 1Learn software testing with tech partnerz 1
Learn software testing with tech partnerz 1
Techpartnerz
 

Similar to Furore devdays2017 tdd-2-advanced (20)

Writing Acceptance Tests Using Fitnesse
Writing Acceptance Tests Using FitnesseWriting Acceptance Tests Using Fitnesse
Writing Acceptance Tests Using Fitnesse
 
Choosing right-automation-tool
Choosing right-automation-toolChoosing right-automation-tool
Choosing right-automation-tool
 
Accelerate and Automate PeopleSoft 9.2/9.1 Testing with PeopleSoft Test Frame...
Accelerate and Automate PeopleSoft 9.2/9.1 Testing with PeopleSoft Test Frame...Accelerate and Automate PeopleSoft 9.2/9.1 Testing with PeopleSoft Test Frame...
Accelerate and Automate PeopleSoft 9.2/9.1 Testing with PeopleSoft Test Frame...
 
KrishnaToolComparisionPPT.pdf
KrishnaToolComparisionPPT.pdfKrishnaToolComparisionPPT.pdf
KrishnaToolComparisionPPT.pdf
 
FUNTASY - Functional testing automated system
FUNTASY - Functional testing automated systemFUNTASY - Functional testing automated system
FUNTASY - Functional testing automated system
 
Beginners overview of automated testing with Rspec
Beginners overview of automated testing with RspecBeginners overview of automated testing with Rspec
Beginners overview of automated testing with Rspec
 
Unit Testng with PHP Unit - A Step by Step Training
Unit Testng with PHP Unit - A Step by Step TrainingUnit Testng with PHP Unit - A Step by Step Training
Unit Testng with PHP Unit - A Step by Step Training
 
No Devops Without Continuous Testing
No Devops Without Continuous TestingNo Devops Without Continuous Testing
No Devops Without Continuous Testing
 
Test Automation using UiPath Test Suite - Developer Circle Part-3 - 07262022.pdf
Test Automation using UiPath Test Suite - Developer Circle Part-3 - 07262022.pdfTest Automation using UiPath Test Suite - Developer Circle Part-3 - 07262022.pdf
Test Automation using UiPath Test Suite - Developer Circle Part-3 - 07262022.pdf
 
Best Practices in Web Service Design
Best Practices in Web Service DesignBest Practices in Web Service Design
Best Practices in Web Service Design
 
Testing, a pragmatic approach
Testing, a pragmatic approachTesting, a pragmatic approach
Testing, a pragmatic approach
 
Getting Started with Test-Driven Development at Longhorn PHP 2023
Getting Started with Test-Driven Development at Longhorn PHP 2023Getting Started with Test-Driven Development at Longhorn PHP 2023
Getting Started with Test-Driven Development at Longhorn PHP 2023
 
Perforce Web Services
Perforce Web ServicesPerforce Web Services
Perforce Web Services
 
Context Driven Automation Gtac 2008
Context Driven Automation Gtac 2008Context Driven Automation Gtac 2008
Context Driven Automation Gtac 2008
 
26.1a.Introduction to DEVOPS_v2.pptx
26.1a.Introduction to DEVOPS_v2.pptx26.1a.Introduction to DEVOPS_v2.pptx
26.1a.Introduction to DEVOPS_v2.pptx
 
Automated Developer Testing: Achievements and Challenges
Automated Developer Testing: Achievements and ChallengesAutomated Developer Testing: Achievements and Challenges
Automated Developer Testing: Achievements and Challenges
 
Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Acceptance & Functional Testing with Codeception - SunshinePHP 2016Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Acceptance & Functional Testing with Codeception - SunshinePHP 2016
 
BDD for APIs
BDD for APIsBDD for APIs
BDD for APIs
 
Acceptance & Functional Testing with Codeception - Devspace 2015
Acceptance & Functional Testing with Codeception - Devspace 2015 Acceptance & Functional Testing with Codeception - Devspace 2015
Acceptance & Functional Testing with Codeception - Devspace 2015
 
Learn software testing with tech partnerz 1
Learn software testing with tech partnerz 1Learn software testing with tech partnerz 1
Learn software testing with tech partnerz 1
 

More from DevDays

Consent dev days
Consent dev daysConsent dev days
Consent dev days
DevDays
 
Mohannad hussain dicom and imaging tools
Mohannad hussain   dicom and imaging toolsMohannad hussain   dicom and imaging tools
Mohannad hussain dicom and imaging tools
DevDays
 
Mohannad hussain community track - siim dataset & dico mweb proxy
Mohannad hussain   community track - siim dataset & dico mweb proxyMohannad hussain   community track - siim dataset & dico mweb proxy
Mohannad hussain community track - siim dataset & dico mweb proxy
DevDays
 
Transforming other content (grahame)
Transforming other content (grahame)Transforming other content (grahame)
Transforming other content (grahame)
DevDays
 
Structure definition 101 (ewout)
Structure definition 101 (ewout)Structure definition 101 (ewout)
Structure definition 101 (ewout)
DevDays
 
Quality improvement dev days-2017
Quality improvement dev days-2017Quality improvement dev days-2017
Quality improvement dev days-2017
DevDays
 
Furore devdays 2017- oai
Furore devdays 2017- oaiFurore devdays 2017- oai
Furore devdays 2017- oai
DevDays
 
Furore devdays 2017 - implementation guides (lloyd)
Furore devdays 2017 - implementation guides (lloyd)Furore devdays 2017 - implementation guides (lloyd)
Furore devdays 2017 - implementation guides (lloyd)
DevDays
 
Connectathon opening 2017
Connectathon opening 2017Connectathon opening 2017
Connectathon opening 2017
DevDays
 
20171127 rene spronk_messaging_the_unloved_paradigm
20171127 rene spronk_messaging_the_unloved_paradigm20171127 rene spronk_messaging_the_unloved_paradigm
20171127 rene spronk_messaging_the_unloved_paradigm
DevDays
 
Opening student track
Opening student trackOpening student track
Opening student track
DevDays
 
Furore devdays 2017- continua implementing fhir
Furore devdays 2017- continua implementing fhirFurore devdays 2017- continua implementing fhir
Furore devdays 2017- continua implementing fhir
DevDays
 
Fhir dev days_advanced_fhir_terminology_services
Fhir dev days_advanced_fhir_terminology_servicesFhir dev days_advanced_fhir_terminology_services
Fhir dev days_advanced_fhir_terminology_services
DevDays
 
Distributing cds dev days-2017
Distributing cds dev days-2017Distributing cds dev days-2017
Distributing cds dev days-2017
DevDays
 

More from DevDays (14)

Consent dev days
Consent dev daysConsent dev days
Consent dev days
 
Mohannad hussain dicom and imaging tools
Mohannad hussain   dicom and imaging toolsMohannad hussain   dicom and imaging tools
Mohannad hussain dicom and imaging tools
 
Mohannad hussain community track - siim dataset & dico mweb proxy
Mohannad hussain   community track - siim dataset & dico mweb proxyMohannad hussain   community track - siim dataset & dico mweb proxy
Mohannad hussain community track - siim dataset & dico mweb proxy
 
Transforming other content (grahame)
Transforming other content (grahame)Transforming other content (grahame)
Transforming other content (grahame)
 
Structure definition 101 (ewout)
Structure definition 101 (ewout)Structure definition 101 (ewout)
Structure definition 101 (ewout)
 
Quality improvement dev days-2017
Quality improvement dev days-2017Quality improvement dev days-2017
Quality improvement dev days-2017
 
Furore devdays 2017- oai
Furore devdays 2017- oaiFurore devdays 2017- oai
Furore devdays 2017- oai
 
Furore devdays 2017 - implementation guides (lloyd)
Furore devdays 2017 - implementation guides (lloyd)Furore devdays 2017 - implementation guides (lloyd)
Furore devdays 2017 - implementation guides (lloyd)
 
Connectathon opening 2017
Connectathon opening 2017Connectathon opening 2017
Connectathon opening 2017
 
20171127 rene spronk_messaging_the_unloved_paradigm
20171127 rene spronk_messaging_the_unloved_paradigm20171127 rene spronk_messaging_the_unloved_paradigm
20171127 rene spronk_messaging_the_unloved_paradigm
 
Opening student track
Opening student trackOpening student track
Opening student track
 
Furore devdays 2017- continua implementing fhir
Furore devdays 2017- continua implementing fhirFurore devdays 2017- continua implementing fhir
Furore devdays 2017- continua implementing fhir
 
Fhir dev days_advanced_fhir_terminology_services
Fhir dev days_advanced_fhir_terminology_servicesFhir dev days_advanced_fhir_terminology_services
Fhir dev days_advanced_fhir_terminology_services
 
Distributing cds dev days-2017
Distributing cds dev days-2017Distributing cds dev days-2017
Distributing cds dev days-2017
 

Recently uploaded

Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
chanes7
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
Nguyen Thanh Tu Collection
 
How to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRMHow to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRM
Celine George
 
Advanced Java[Extra Concepts, Not Difficult].docx
Advanced Java[Extra Concepts, Not Difficult].docxAdvanced Java[Extra Concepts, Not Difficult].docx
Advanced Java[Extra Concepts, Not Difficult].docx
adhitya5119
 
S1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptxS1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptx
tarandeep35
 
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdfANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
Priyankaranawat4
 
How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17
Celine George
 
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptxChapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Mohd Adib Abd Muin, Senior Lecturer at Universiti Utara Malaysia
 
clinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdfclinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdf
Priyankaranawat4
 
Community pharmacy- Social and preventive pharmacy UNIT 5
Community pharmacy- Social and preventive pharmacy UNIT 5Community pharmacy- Social and preventive pharmacy UNIT 5
Community pharmacy- Social and preventive pharmacy UNIT 5
sayalidalavi006
 
The Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collectionThe Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collection
Israel Genealogy Research Association
 
World environment day ppt For 5 June 2024
World environment day ppt For 5 June 2024World environment day ppt For 5 June 2024
World environment day ppt For 5 June 2024
ak6969907
 
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UPLAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
RAHUL
 
The basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptxThe basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptx
heathfieldcps1
 
Azure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHatAzure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHat
Scholarhat
 
How to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold MethodHow to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold Method
Celine George
 
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Dr. Vinod Kumar Kanvaria
 
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptxC1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
mulvey2
 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
GeorgeMilliken2
 
Smart-Money for SMC traders good time and ICT
Smart-Money for SMC traders good time and ICTSmart-Money for SMC traders good time and ICT
Smart-Money for SMC traders good time and ICT
simonomuemu
 

Recently uploaded (20)

Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 CẢ NĂM - GLOBAL SUCCESS - NĂM HỌC 2023-2024 (CÓ FI...
 
How to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRMHow to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRM
 
Advanced Java[Extra Concepts, Not Difficult].docx
Advanced Java[Extra Concepts, Not Difficult].docxAdvanced Java[Extra Concepts, Not Difficult].docx
Advanced Java[Extra Concepts, Not Difficult].docx
 
S1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptxS1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptx
 
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdfANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
 
How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17
 
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptxChapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
 
clinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdfclinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdf
 
Community pharmacy- Social and preventive pharmacy UNIT 5
Community pharmacy- Social and preventive pharmacy UNIT 5Community pharmacy- Social and preventive pharmacy UNIT 5
Community pharmacy- Social and preventive pharmacy UNIT 5
 
The Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collectionThe Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collection
 
World environment day ppt For 5 June 2024
World environment day ppt For 5 June 2024World environment day ppt For 5 June 2024
World environment day ppt For 5 June 2024
 
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UPLAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
LAND USE LAND COVER AND NDVI OF MIRZAPUR DISTRICT, UP
 
The basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptxThe basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptx
 
Azure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHatAzure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHat
 
How to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold MethodHow to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold Method
 
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
 
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptxC1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
 
Smart-Money for SMC traders good time and ICT
Smart-Money for SMC traders good time and ICTSmart-Money for SMC traders good time and ICT
Smart-Money for SMC traders good time and ICT
 

Furore devdays2017 tdd-2-advanced

  • 1. FHIR® is the registered trademark of HL7 and is used with the permission of HL7. The Flame Design mark is the registered trademark of HL7 and is used with the permission of HL7. Amsterdam, 15-17 November | @fhir_furore | #fhirdevdays17 | www.fhirdevdays.com Test Driven Development II - Advanced Richard Ettema, AEGIS.net, Inc.
  • 2. Presented by • Name: Richard Ettema • Position: • Lead Consultant, AEGIS.net, Inc. • FHIR® Certified Implementer • Background: • 34+ years IT industry experience • 14+ years leading HIT development/implementation efforts • 4+ years contributing to the HL7® FHIR® specification (focus on testing) • Sr. Architect / Lead Developer for the Touchstone Project • Author of the AEGIS WildFHIR public test server and client
  • 3. Test Driven Development with FHIR Intro Session Review • To ensure interoperability between applications claiming conformance to the specification, a testing framework has been established within the FHIR specification itself https://www.hl7.org/fhir/STU3/testing.html • This framework defines a Test Engine for processing a TestScript resource as a natural language, computable format of a test case • The TestScript resource is an implementation-agnostic description of tests that allows test engines to evaluate if a FHIR implementation conforms with the FHIR specification https://www.hl7.org/fhir/STU3/testscript.html
  • 4. • Testing workflow example • How can we trust that the correction is being tested in the same way? Can we trust either test outcome? Known data facilitates known, expected outcomes We will review and examine how to ensure “Reliable and Repeatable Testing” during the Hands-on Exercises using a “Two Users, Same Data” scenario Test Passes Run Test Again Developer Correction Test FailsRun Test Reliable and Repeatable Testing
  • 5. Identifying Your Testing Criteria; a.k.a. Asserts • Testing simple values • Is this the patient I expected? • Is this the operation response I expected? • Did I get multiple matches when I expected one? • Testing specification conformance • Is this element required? • Is this code value correct? • Testing conditionality or constraints • Can this element be expressed more than one way and still be compliant? • Is this element is only required when another element is present?
  • 6. Asserts can perform… • simple operations • standard assert operators are constrained to the following: equals | notEquals | in | notIn | greaterThan | lessThan | empty | notEmpty | contains | notContains | eval • specification allows for use of XPath or JSONPath expressions • complex evaluations • specification allows for rules to be defined within the assert • specification allows for use of FHIRPath* expressions *FHIRPath is supported within the TestScript resource and by the Touchstone test engine, but will not be a focus of this session. To learn more about FHIRPath, see http://hl7.org/fhirpath
  • 7. Complex Asserts • Are used when testing conditionality, constraints or simplifying an existing test construct • Support the use of FHIRPath • FHIRPath has expressions, functions, operations • Far more functionality than found in the simple assert operators • Built-in expressions such as dateTime and quantity • Expressions can contain operators • Functions like isDistinct, count, subsetOf, supersetOf • Support Rules and Rulesets (high level language scripted logic) • Touchstone Rules Engine supports Groovy, Schematron and XSLT
  • 8. Complex Asserts - FHIRPath Example • FHIRPath provides a syntax neutral way to access the contents of a resource and can simplify assert logic constructs Assert condition: “Confirm that the searchset Bundle total number of entries is at least one (1).” • Let’s compare XPath and JSONPath to FHIRPath…
  • 9. Complex Asserts - FHIRPath Example Comparison with XPath and JSONPath • XPath assert <assert> <operation value=“greaterThan” /> <path value=“/Bundle/total” /> <value value=“0” /> </assert> • JSONPath assert <assert> <operation value=“greaterThan” /> <path value=“.total” /> <value value=“0” /> </assert> • FHIRPath assert (equivalent logic) <assert> <expression value=“Bundle.total.toInteger() &gt; 0” /> </assert> • FHIRPath assert (alternative logic) <assert> <expression value=“Bundle.entry.count() &gt; 0” /> </assert>
  • 10. Complex Asserts - Rules and Rulesets • The TestScript resource allows the use of Rules and Rulesets within the assert • Rules are called during TestScript execution • In Touchstone, the Rules are hosted within the Test Definition folders • Rules may be viewed and will be displayed in Test Results if selected • Rulesets are simply collections of one or more Rules • Allows for the definition of a group of Rules to be referenced within the TestScript in an efficient manner We will review and examine Rules and Rulesets during the Hands-on Exercises
  • 11. FHIR Client or Peer-to-Peer Testing • TestScripts in Touchstone can be either Server-only, Client (Peer-to- Peer), or Multi-actor • Server-only: Touchstone initiates requests to the destination FHIR System and evaluates the response • Client (Peer-to-Peer): Touchstone waits for a request from the origin FHIR System to be received, evaluates the request, sends to the destination FHIR System, and evaluates the response • Multi-actor: Touchstone may act as the initiating system along with other FHIR Test Systems acting as either a Client or Server
  • 12. Client (Peer-to-Peer) Testing - Test Setup • Select a Client TestScript from the Test Definitions list • Select and fill in any test data necessary for test execution • Origin Test System (Client) • Destination Test System (Server) • (Dynamic) Variables
  • 13. Client (Peer-to-Peer) Testing - Test Execution
  • 14. Client (Peer-to-Peer) Testing - TestScript Execution We will review and examine Client Testing during the Hands-on Exercises
  • 15. Captured Message Exchanges • The Exchanges dashboard in Touchstone allows users to view all captured request and response messages • Touchstone will match an exchange with a test execution using these checks: • If your test server is already defined within Touchstone and is publicly accessible, the message can be matched by originating IP address • If that is not possible, the system attempts to use USER_KEY and ORG_KEY • Else, the system cannot match the message to a test execution
  • 16. USER_KEY and ORG_KEY • USER_KEY and ORG_KEY are special placeholders • They can be sent by the client system as an HTTP request header or within the request payload • They identify the client system when the machine name or IP address would not
  • 17. Introducing the Touchstone APIs • Test executions can be launched and monitored via remote RESTful web services • Provides the means to integrate Touchstone into your organization’s test executions for: • Internal automated regressions tests • Continuous Integration build processes • Documentation and example messages are available • Supported formats – JSON and XML
  • 18. Touchstone API Capabilities • The Touchstone APIs allow for many of the same non-administrative functions as the User Interface • Test executions launched on behalf of a remote test user via Touchstone API will be visible to all members of your organization on the Touchstone UI • Any member of your organization can log in to the Touchstone UI and investigate test failures if needed
  • 19. Touchstone API Services POST authenticate  Authenticate with Touchstone; return new API session key POST testExecution  Launch a new test execution for an existing Test Setup GET testExecution  Return the status of a know test execution GET testExecDetail  Return summary status of all test execution TestScripts GET scriptExecDetail  Return test execution single TestScript details GET testReport  Same as GET scriptExecDetail except returns FHIR TestReport
  • 20. Touchstone API - Jenkins CI Server Integration Example • The Touchstone User Guide documents a Jenkins CI Server Integration Example • https://touchstone.aegis.net/touchstone/TouchstoneUserGuide, section ‘Touchstone API – Jenkins Integration Example’ • Illustrates the use of the Jenkins Groovy Plugin • Builds on the example code from the previous ‘Touchstone API – Definition’ section Due to not having a publicly available Jenkins CI Server at this event, there is no corresponding Hands-on Exercises for this topic.
  • 21. Conformance Testing • Conformance Testing validates a system against known standards • FHIR Specification (including Implementation Guides) • Version support (forward/backward compatibility) • Continuous Conformance Testing shows that an organization is currently conformant, but also committed to remain conformant • Future development minded - interoperability needs to be addressed on a continuous basis • Development Aid - developers can integrate FHIR conformance testing into their build cycle to avoid costly conformance code rewrites later • Regression testing - validate that changes and enhancements are also conformant
  • 23. Hands on Exercises • Reliable and Repeatable Testing - Two Users, Same Data • Complex Asserts • FHIRPath comparison to XPath and JSONPath • Rules and Rulesets • Advanced TestScripts • FHIR Client / Peer-to-Peer • Conformance Analytics Dashboard • Connectathon Test Track • We will continue our review of one of the test tracks for the next HL7 FHIR Connectathon 17 event and the development of TestScripts
  • 25. FHIR® is the registered trademark of HL7 and is used with the permission of HL7. The Flame Design mark is the registered trademark of HL7 and is used with the permission of HL7. Amsterdam, 15-17 November | @fhir_furore | #fhirdevdays17 | www.fhirdevdays.com Thank you!