Open in app

Sign In

Write

Sign In

Pavel Saman
Pavel Saman

86 Followers

Home

About

Sep 13

Code Coverage In Different Tools

Here’s a short rant about code coverage. I have a project in TypeScript. It’s a tiny tool to calculate code coverage from LCOV files. I’ve written unit tests to check it’s functionality and handling of various types of data. …

Code Coverage

2 min read

Code Coverage In Different Tools
Code Coverage In Different Tools
Code Coverage

2 min read


Sep 3

Quick Tip: refactoring.guru

Here is a quick tip if you want to become a better coder. Refactoring.guru is a great resource for learning about refactoring or design patterns. There are some free resources and two paid courses about the two topics. I’ve bought the one about refactoring and it’s worth the price. Enjoy and happy learning :)

Coding

1 min read

Coding

1 min read


Jan 21

Scopes and Variable Shadowing in JS

If I give you the following example code: const age = 30; function func() { const age = 31; console.log(age); for(let i = 0; i < 2; i++) { const age = 32; console.log(age); } } func(); console.log(age); What will be printed to the console? Try to answer before you…

JavaScript

2 min read

JavaScript

2 min read


Jan 19

Postman — Covert String to base64

Sometimes you need to get base64 encoded string inside Postman. Or decode a base64 encoded string. I think two easy ways are: const base64encoded = btoa('stringToEncode'); // c3RyaW5nVG9FbmNvZGU= const decoded = atob(base64encoded); // stringToEncode Another way to encode might be: Buffer.from('stringToEncode').toString('base64'); // c3RyaW5nVG9FbmNvZGU=

Base64

1 min read

Base64

1 min read


Jan 18

Get All NPM Scripts from package.json

When working with package.json files, I often need to get all scripts to find the one I want to run. To do that, I can either open the file and find the script I need, which is slow, or I can use jq to get all the NPM scripts right…

NPM

1 min read

NPM

1 min read


Jan 2

Send Mocha Test Result to New Relic

I’ve talked about Mocha test results a few times — in Mocha JSON Report(er) and Cache Mocha Test Results And Run Only Failed Test Files On Re-runs. Today I’ll add one more piece — sending Mocha test results to New Relic. New Relic is a monitoring platform that can gather…

Mocha

3 min read

Send Mocha Test Result to New Relic
Send Mocha Test Result to New Relic
Mocha

3 min read


Dec 26, 2022

Cache Mocha Test Results And Run Only Failed Test Files On Re-runs

Mocha can generate a JSON file with test results. It might be sometimes useful to find all failed test files, e.g. when I want to re-run only tests from such test files. Running all automated tests might be time-consuming, so you might want to look for various ways to run…

Mocha

5 min read

Cache Mocha Test Results And Run Only Failed Test Files On Re-runs
Cache Mocha Test Results And Run Only Failed Test Files On Re-runs
Mocha

5 min read


Dec 25, 2022

Keep Git Authors in Order With Gitmailmap

Gitmailmap is a good way to keep the git authors in order. The official git documentation says: If the file .mailmap exists at the toplevel of the repository, or at the location pointed to by the mailmap.file or mailmap.blob …

Git

2 min read

Git

2 min read


Dec 24, 2022

Channel Notifications Are Not Always Useful

I see a lot of content online about creating channel notification about the results of automated checks. I don’t think this is as useful as such posts sometimes try to portray. What I have experienced is that there’s usually too many (Slack) channels that it is impossible and ineffective to…

Data

1 min read

Data

1 min read


Dec 23, 2022

End to End is Usually Not End to End

What? Why? I’ve recently noticed that we kind of use end-to-end for almost anything that involves more than one tiny part of the system. That is not completely wrong of course, but I find it misleading anyway, I’ll try to explain why. My current situation is something along these points: …

End To End Testing

3 min read

End To End Testing

3 min read

Pavel Saman

Pavel Saman

86 Followers

SW Tester

Following
  • Melissa Fisher

    Melissa Fisher

  • Scott H. Young

    Scott H. Young

  • Ryan Craven

    Ryan Craven

  • Pavol Luptak

    Pavol Luptak

  • Amet Umierov

    Amet Umierov

See all (16)

Help

Status

Writers

Blog

Careers

Privacy

Terms

About

Text to speech

Teams