Image for post
Image for post
Photo by Ben on Unsplash

PHPUnit has been blowing away its competition for more than 5 years now. With the use of the right PHPUnit assertions, you can get the most benefit out of PHPUnit. In this post, we will look into some popular and very useful PHPUnit assertions you should be using day to day in your PHPUnit tests. Let’s get cracking!

PHPUnit Assertions to know about

Currently, PHPUnit is at version 9.5. As per the latest docs, there are 60 assert methods you can use in your PHPUnit tests.

These PHPUnit assertions range from checking if array has a key to the ever-popular assert equals to the not…


Image for post
Image for post
Image from Pixabay

The ability of software to heal from unexpected events is software resilience. This means a software engineer has to anticipate unexpected events and account for them. The solution for creating this fault tolerance can be in code or on the infrastructure layer.

Distributed systems will fail, a resilient software system will not try to avoid failure but expect it and respond gracefully.

In this post, we will look into some aspects that you need to be careful to have software resilience.

What is software resilience?

Software Engineering Institute blog of Carnegie Mellon University indicates:

“Basically, a system is resilient if it continues to carry…


Image for post
Image for post
Image modified, original on Pixabay

When I first thought about taking a social media break I thought it would be difficult. On the contrary, a 30-day social media break that I took proved to be quite satisfying.

In this post, we will look at how to take a social media break in 4 steps where you have more chances of becoming successful at it.

What is a social media break?

A social media break is a time where you don’t use social media at varying degrees.

You could be completely off it, for example not posting as well as not consuming any content from the feeds or engaging in other’s posts.


Image for post
Image for post
Photo by Christina on Unsplash

There are many qualities of a great software engineer that will make you stand out. Among them, these 3 are crucial for you to become a great software engineer and leave the competition behind.

Surely technical qualities matter a lot to be counted as a superior software engineer. On the other hand, this post is geared towards the non-technical aspects of software engineering.

Non-technical Software engineer qualities to work on

Without a doubt, a great software engineer writes working, testable and maintainable code. Numerous technical skills will be required to differentiate yourself as a great software engineer. …


Image for post
Image for post
Background Image from Unsplash

Node.js can be used efficiently with relational databases like PostgreSQL. In this post about Node.js PostgreSQL tutorial, we are going to build a REST API for Quotes step-by-step using Express Js.

You can read my previous tutorial to try Node.js with MySQL. You should read this guide to use Docker with Node.js, it is also a step-by-step guide. You can, of course, carry on with this Node.js with PostgreSQL tutorial :).

For your convinience, each step has been carved out as a distinct pull reqeust so that you can follow the tutorial with ease.

Prerequisites

  1. You have Node.js (preferably Node 14.x)…


Image for post
Image for post
Network Image by Bethany Drouin from Pixabay

Software scalability is an interesting issue to have. Making software scalable consists of multiple factors, we discuss some dev (code) related and a few operations (platforms) associated aspects in this blog post.

We will discuss more on how to write software (software development) and how you run the software (operations) to make the software scalable. For beginners, cost and scalability are generally proportional, let’s get cracking.

Table of contents

· What is software scalability? · Software Scalability dev point of view ∘ 1. Scalable software with efficient code ∘ 2. Asynchronous processing ∘ 3. Write stateless applications for scalable software · Software Scalability…


Image for post
Image for post
Image from Pixabay

Software Engineering podcasts have been my companion for a long time. I have listened to software engineer podcasts for more than a decade. Software Engineering podcasts give you the latest news and views in a great format that is equally easy to consume too. You can also read the previous parts 1, 2, 3, and 4. Here are the 3 podcasts all software engineers should subscribe to now:

Command Line Heroes (from Redhat) by Saron Yitbarek

Command line heroes is a gem of a podcast. The topics are well researched and in-depth. It covers a wide range of topics that are very relevant to all software engineers. I…


Image for post
Image for post
Speedboat Image by Herbert Aust from Pixabay

PHPUnit is the de-facto testing library for PHP. With the use of PCov, you can speed up PHPUnit code coverage by 2–5 times for PHP 7.0+ application. In this post, we will compare the results of an experiment I did on Laravel framework tests.

The tests were run without coverage, then with Xdebug coverage, and finally with PCov all on Github actions. PCov took half the time to run the PHPUnit tests with code coverage compared to Xdebug, let’s go to the numbers.


Image for post
Image for post
Photo by Cameron Venti on Unsplash

In this post, we will see a docker build example of a Node.js API application starting from slow and ending up in a ~10x faster build. I have already talked about the reasons to use docker for the development environment. I have also mentioned how docker changed the way we software engineers work and multi-stage docker build in past posts. For this one let’s focus on the docker build example with a faster build in mind.

Information before jumping in

  1. Familiarity with Docker and the docker build process is required
  2. All examples are based on Docker version 19.03.13, build 4484c46d9d on a Mac
  3. The…


Image for post
Image for post

While the popularity of Node.js is increasing, PHP’s traction is going down a tiny bit. With that context, this post is going to elaborate on 5 must-know practical aspects of using Node.js for PHP developers. These will be things usually no-one talks or writes about, time to get going.

Geshan Manandhar

Lead Software Engineer, Agile follower. Technologist, Google Developer Expert. Blogging at geshan.com.np

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store