We are a UK consultancy who specialise in Data, Analytics, AI, and Cloud Native App Dev on Microsoft Fabric, Databricks & Azure.
What We Do
We help small teams achieve big things! We specialize in modernising data & analytics platforms, infusing AI, and creating compelling apps.
Who We Help
Whether a global brand, or an ambitious scale-up, we help the small teams who power them, to achieve more.
What We Think
We love to share our hard won learnings, through blogs, talks or thought leadership. This is the good stuff!
Contact Us
If you would like to ask us a question, talk about your requirements, or arrange a chat, we would love to hear from you. Want to know more about how endjin could help you?
I recently demonstrated how it was possible to automate the deployment of R models to Azure Machine Learning through Azure DevOps. Of course, this is only part of the story; what about testing? It is important to ensure that all production code is adequately tested, and R is no different. Writing unit tests for R models is straight-forward using the popular testthat R package. With the help of some PowerShell it is possible to run these tests as part a continuous integration build and deployment pipeline.
Why should data scientists write unit tests for R models?Production R code deserves the same quality assurance as any other code. Unit tests catch regression errors when models are updated, validate edge cases in data transformations, and provide documentation of expected behaviour. The testthat package makes writing R tests straightforward with familiar assertion patterns.How do you run R unit tests in an Azure DevOps pipeline?PowerShell scripts bridge the gap between Azure DevOps build agents and R execution. The scripts invoke R with testthat to run your test suite and translate the results into a format Azure DevOps understands. This enables R tests to appear alongside other test results and fail the build when tests fail.
Jess has over 25 years' experience helping companies succeed through the smart use of technology. He spent most of his career working for leading Microsoft partners across the UK and Australia and was Principal at endjin, working with clients to envision and execute disciplined innovation programmes.