Join us on a literary world trip!
Add this book to bookshelf
Grey
Write a new comment Default profile 50px
Grey
Subscribe to read the full book or read the first pages for free!
All characters reduced
Test-Driven Development in Go - A practical guide to writing idiomatic and efficient Go tests through real-world examples - cover

Test-Driven Development in Go - A practical guide to writing idiomatic and efficient Go tests through real-world examples

Adelina Simion

Publisher: Packt Publishing

  • 0
  • 0
  • 0

Summary

Experienced developers understand the importance of designing a comprehensive testing strategy to ensure efficient shipping and maintaining services in production. This book shows you how to utilize test-driven development (TDD), a widely adopted industry practice, for testing your Go apps at different levels. You’ll also explore challenges faced in testing concurrent code, and learn how to leverage generics and write fuzz tests.
The book begins by teaching you how to use TDD to tackle various problems, from simple mathematical functions to web apps. You’ll then learn how to structure and run your unit tests using Go’s standard testing library, and explore two popular testing frameworks, Testify and Ginkgo. You’ll also implement test suites using table-driven testing, a popular Go technique. As you advance, you’ll write and run behavior-driven development (BDD) tests using Ginkgo and Godog. Finally, you’ll explore the tricky aspects of implementing and testing TDD in production, such as refactoring your code and testing microservices architecture with contract testing implemented with Pact. All these techniques will be demonstrated using an example REST API, as well as smaller bespoke code examples.
By the end of this book, you’ll have learned how to design and implement a comprehensive testing strategy for your Go applications and microservices architecture.
Available since: 04/28/2023.
Print length: 342 pages.

Other books that might interest you

  • Data Analytics Unlocked - Turning Data into Actionable Insights - cover

    Data Analytics Unlocked -...

    Abigail Allen

    • 0
    • 0
    • 0
    "Data Analytics Unlocked: Turning Data into Actionable Insights" is a must-read for anyone who wants to use complicated data to their advantage. This book goes into great detail about the ideas, methods, and tools used in data analytics. It's written for both newcomers and seasoned workers. It details important ideas like gathering data, cleaning data, and statistical analysis. It also talks about more advanced ways to understand and show data. 
    The book is structured to facilitate the transition from theory to practice, offering step-by-step guidance and real-life cases that illustrate the correct application of analytical methods. Readers will learn how to transform raw data into actionable information, enabling them to make informed decisions and devise effective business strategies. By emphasizing practical, actionable advice, the book equips readers with the tools they can immediately apply in their professional roles, enhancing their problem-solving abilities and boosting their performance. 
    "Data Analytics Unlocked" gives you the information and tools you need to achieve whether you want to make better decisions based on data or move up in your data analytics job. It's a complete guide that gives readers the tools to find data's true potential and use it for strategic growth and a competitive edge.
    Show book
  • Human Hacked - My Life and Lessons as the World's First Augmented Ethical Hacker - cover

    Human Hacked - My Life and...

    Len Noe

    • 0
    • 0
    • 0
    Discover the future of cybersecurity through the eyes of the world's first augmented ethical hacker 
     
     
     
    In Human Hacked by Len Noe, a pioneering cyborg with ten microchips implanted in his body, you'll find a startlingly insightful take on the fusion of biology and technology. The author provides a groundbreaking discussion of bio-implants, cybersecurity threats, and defenses. 
     
     
     
    Human Hacked offers a comprehensive guide to understanding an existing threat that is virtually unknown. The book provides: 
     
     
     
    ● Exposure of a subculture of augmented humans hiding in plain sight 
     
     
     
    ● Explorations of the frontier of bio-Implants, showing you the latest advancements in the tech and how it paves the way for access to highly restricted technology areas 
     
     
     
    ● Discussions of cybersecurity tactics, allowing you to gain in-depth knowledge of phishing, social engineering, MDM restrictions, endpoint management, and more to shield yourself and your organization from unseen threats 
     
     
     
    ● A deep understanding of the legal and ethical landscape of bio-implants as it dives into the complexities of protections for augmented humans and the ethics of employing such technologies in the corporate and government sectors
    Show book
  • Mosaic of Minds - Navigating the Coexistence of Artificial Intelligence and Humanity - cover

    Mosaic of Minds - Navigating the...

    Songyee Yoon

    • 0
    • 0
    • 0
    Forging a More Humane Future through Ethical AI CollaborationThe rapid development of AI is bringing revolutionary changes that raise complex ethical questions without clear solutions. As AI becomes an integral part of human society, how can we ensure it evolves responsibly and ethically? Songyee Yoon draws from conversations with pioneering AI experts to provide insight into building a framework for the coexistence of humans and machines. Exploring philosophical, educational, engineering, and societal perspectives, Mosaic of Minds offers thought-provoking discussions on AI's potential benefits and risks.This insightful book encourages collaborative efforts between diverse fields to develop AI that augments humanity, arguing that open communication and debate will reveal solutions hidden in differences. Ultimately, it makes a compelling case that by working together, we can create a new order where AI assists in solving humanity’s problems.
    Show book
  • In Days Gone By - cover

    In Days Gone By

    Mike Blake

    • 0
    • 0
    • 0
    "This Poem 'In Days Gone By - Newbury'. Part 3 of the series Nature: Natural Healing.A time when most of the UK Countryside was criss-crossed by small roads and slow moving cars.And the pace was slower and more durable for nature.A delicate balance had been formed between the new motor car and the hedgerows and byways that struck a chord of harmony between each other. Broken now, with too many Motorways and not enough cycle lanes - leaving nature, floundering.I the Author have been writing Poetry for around 20 years. Most of it has been published on Amazon. I write on varied topics which resonate with what I'm thinking or studying at that time.Credit for the artwork on this piece, goes to Mike Miko for his interpretation of this poem into pictorial Art form." His skill in depicting the scenes of the Newbury bypass running through the heart of a forest, with a ghostly image of Swampies son, was truly remarkable.
    Show book
  • Psilocybin Handbook - Using the Wisdom of Mushrooms for Personal Growth Spiritual Development and Healing Includes step-by-step guides to safely sourcing testing dosing ingesting and integrating - cover

    Psilocybin Handbook - Using the...

    Andre Silas Chavez

    • 0
    • 0
    • 0
    Don't just take a trip. Go on a journey. 
    Do you crave a deeper understanding of yourself, or feel there is an elusive missing piece? If you are ready to move from curiosity to confident exploration, embark on an inner journey with psilocybin. The Psilocybin Handbook, will show you:how psychedelics influence your brain to bring forth new ideas, emotions, and insightswhy psilocybe mushrooms have been used in religions and rituals for thousands of yearswhat being in an altered state could feel like, and what you can expect to experienceways to properly determine and confirm your ideal dosagehow to create the ideal environment and mental state to minimize the risk, and maximize the benefit of psilocybinoptions for regular microdosing strategies that are safe and effectiveintegration techniques to turn your experiences into a holistic personal growth program 
    Whether you're a curious beginner or a seasoned traveler, this book equips you with the knowledge and confidence to navigate the realm of psilocybe mushrooms. The Psilocybin Handbook is your essential guide to unlocking the transformative potential of this ancient plant medicine.
    Show book
  • How to start a business with almost no Money - Bootstrap Blueprint - cover

    How to start a business with...

    Andrine Mendez

    • 0
    • 0
    • 0
    Ever dreamed of starting your own business but felt held back by a lack of money, connections, or experience? This audiobook is for you. 
    Narrated by me, Andrine Mendez, this is not your typical self-help or get-rich-quick guide. Work in Progress is a brutally honest, no-nonsense blueprint for building a business from scratch, even when the odds are stacked against you. I’ve been through it all—bootstrapping, failing, pivoting, scaling, and even exiting a startup—and in this audiobook, I share the real stories, raw lessons, and practical strategies that can help you take the first step toward entrepreneurship. 
    You’ll learn:How to validate your idea before spending time and money.Why storytelling is crucial in attracting customers, investors, and talent.How to deal with failure and turn it into an advantage.The power of iteration and pivoting—why your first idea won’t be your final one. 
    This audiobook is not about theories or fluff—it’s packed with real, actionable steps based on my journey from launching businesses with zero capital to raising funds and exiting a company. You’ll also get bonus chapters on finding grants, startup competitions, and even picking the right brand name. 
    Whether you’re an aspiring entrepreneur, a professional looking for a change, or someone who just needs that extra push to get started, this audiobook is designed to inspire, challenge, and guide you toward building something real. 
    And if you enjoy this, do me a favor—leave a review! Your feedback helps this book reach more people who need it. Now, let’s get started.
    Show book