Author Archives: Alexander

Using discriminated unions to fix Liskov substitution principle violation

As an example of LSP violation, I will consider e-commerce payment system design. One needs to develop generic mechanism for multiple payment service providers (PSP) that are using on checkout step. From the requirements there are different kinds of PSP in terms of integration. … Continue reading

Posted in object-oriented-principles, software-patterns | Leave a comment

FAKE.IIS Add application to existing IIS site

Recently I had a task to change IIS application path in existing IIS site. That was repetitive operation so I decided to write script for it. I recently began to study F# and function programming so decided to try FAKE. There is … Continue reading

Posted in F# | Tagged , | Leave a comment

Tools and libraries to consider when writing autotests

Below is a summary of tools/libraries I have used to build large maintainable suite of auto tests on large web project. Test Framework XUnit xUnit.net is a developer testing framework, built to support Test Driven Development, with a design goal … Continue reading

Posted in Unit test | Tagged | Leave a comment

How to identify process ID in PerfMon

Last time I need to troubleshoot memory leak in IIS process hosted on productions server I decided to start with PerfMon and got stuck on Add Counters screen, where I saw seventeen w3wp (IIS process name) processes up to w3wp#17. Here for … Continue reading

Posted in SysInternals | Tagged | Leave a comment

Software developer productivity

From the starting of my software developer career I wanted to be as productive as possible. And the worst feeling I could have, was when I  was working on a problem that I have already solved before, and need to … Continue reading

Posted in Uncategorized | Leave a comment

Better handling ‘NoSuchElementException’ using simple remote web driver wrapper

While implementing test scenarios, I often write some element selectors wrong and finally get ‘NoSuchElementException’ when run the test. Unfortunately it does not specify, which selector caused the problem. Its message only says the following: OpenQA.Selenium.NoSuchElementException: no such element (Session … Continue reading

Posted in Selenium | Tagged | Leave a comment

MVC configuration – ‘path’ attribute inside ‘location’ section

This is post about specifying path attribute of location section in Web.config file. If you are not familiar with this section, go here Examples in above article concern about ASP.NET where specifying path like ‘Page1.aspx’ is enough. When I started mapping … Continue reading

Posted in ASP.NET | Leave a comment

Add Visual Studio intellisense support for custom configuration section

On my main project we use heavily the awesome log4net framework. It could be quite easily configured but for some advanced configuration I need to constantly check the documentation. I personally prefer to have all required knowledge on how write configuration in … Continue reading

Image | Posted on | 2 Comments

Reading large XML files. Performance comparison of different methods

For really large XML documents larger than 100 MB the idea to load entire document in memory could be not the best choice. Now let’s consider the other ways for reading those large files. For our test lab we will … Continue reading

Posted in XML | Tagged | Leave a comment

Handling test data clean up in SpecFlow

Overview This post describes how to handle scenario level clean-up in a predictable way. Note: This blog post was originally written for SpecFlow 1.9 version. In SpecFlow 2+ version you should use scenario scoped bindings  with  [BeforeScenario] execution order can be … Continue reading

Posted in Selenium, SpecFlow | Tagged , , | Leave a comment