Skip to main content

Posts

Selenium testing in Jenkins with an in-memory X server

This articles explains how to setup integration testing of web applications (that require a browser instance) on a Jenkins server. The article assumes you are able to understand the title. If you need a reminder follow the links below. Automated browser testing (source: Jeremy Keith ) What is Selenium? Read here. What is Jenkins? Read here. What is an X server? Read here. If you are still puzzled, this article is not for you. Integration testing of web application is more complicated than unit testing, because they require a browser instance to be running. In order to run a browser (such as Firefox) you need and X server. The testing server usually doesn't have one. One solution to this is to run the browser instance on another machine through VNC. This has the advantage of not using the same resources as the testing server. However it requires setting up a new machine, and configuring the integration tests to run a browser in it. Another solution is to use Xvfb, a...

Basic cell counting and segmentation in Matlab

Counting cells manually is a tedious error prone process for humans. Given a large data set of microscopy images this task can be achieved much faster by means of basic computer vision techniques. In this tutorial we will segment cells from an image following a method similar to the one presented by Yongming Chen in 1999. The method uses basic morphological operations  and the watershed algorithm to segment the cells. Nowadays better methods for cell segmentation exist. This method was chosen for its simplicity and ease of implementation. We start with an image of cell-like structures by Anna-Katerina Hadjantonakis and Virginia E Papaioannou . A = imread('cells.jpg'); We convert the image to grayscale: I = rgb2gray(A); To be able to extract the dimmer cells, it is necessary to perform some local contrast adjustments I = adapthisteq(I); Objects on the borders can be caused by noise and other artifacts. We can eliminate objects on the borders...

A more confusing Internet with .brand TLDs

A few months ago, I wrote a post proposing to remove top level domains from the internet, as many people don't understand why we need TLDs. At the time I didn't know either. Removing TLDs would simplify browsing an possibly increase security by reducing phishing sites that make use of URL similarity to gain visits to potentially dangerous websites, or sites filled with ads. The ICANN, the body that manages Internet names, has for years been preparing something different but that produces a slightly similar effect than removing TLDs: allowing brands to register their own TLDs . The proposal may soon be approved has been approved . Brands would therefore be able to register their own TLDs. Google could register .google a potentially powerful TLD for their services, like Google Maps: maps.google instead of maps.google.com. Brand TLD don't improve short urls like google.com, but seem to be effective for use in subdomains. Registering a .<brand-name> TLD will cost...

Martha Graham's Google doodle is not a video, is an image (a CSS sprite)

Today's Google doodle is featuring Martha Graham, an American modern dancer. The new doodle looks like a movie, but in fact it is only a CSS sprite. The sprite is this one:  You may be wondering how is the animation/movie appearance achieved if it only uses this static image?  The technique involves CSS sprites. A sprite is a composition of several images grouped together in order to reduce the number of required HTTP request to the server. This way a website with 50 images requires only one request for the large image composition. The entire doodle involves only one sprite, which speeds up loading a lot (compared to loading each frame separately). Google has used this technique to leverage data transfer from the servers and consequently make the animation load faster than a traditional video clip.  So how is this sprite converted to an animation? Pretend you are looking through pierced piece of paper, so that you can only look through th...

Weekend project: Book's I've read

It's been months since I wanted to learn databases and create a dynamic website, but it's only this weekend that I acted. In two day I learned how to use MySQL with PHP in websites and created a small project that I call "Books I've read" that stores a list of books I read (obviously). I am an avid reader and I've been storing the list of books I read (and want to read) in a text document for about a year. Finally, my project moved this list to the cloud and allows me to add, edit and update entries. The app has user authentication, so no one except me can alter my book list. The design was made in a hurry, but is good enough for my needs. Instead of using normal CSS for styling I've used LESS CSS, a dynamic stylesheet language that extends CSS with dynamic behavior, nested rules, mixins and logical operators. LESS CSS has made styling faster, but unfortunately it relies on Javascript. Without Javascript activated the website breaks. And t...

Website complete: presojaidej.com

Presojaidej.com is a service that offers reviews of ideas for a competitive price. This being one of my first websites I developed I want to explain my workflow and reasoning while creating it. Dislaimer: I am only the developer and designer of the website; it is owned by E-amiga, d.o.o. I was given a lot of freedom regarding the look of the website, so it was an enjoying small project. The only guideline I was given is the general form: the client wanted it to be on one page, so that there are fewer clicks required by the user to order a business idea review. I wanted to create a website that looked professional and had a large conversion rate (the percentage of users that order the service after visiting the website). The professional look was achieved with clear lines, and attention to detail: the background patterns, the differences in border colors to imitate slight depth and a snappy feeling on hovering over the buttons among others. The resulting page is easy to scan throug...

The Increased Addictiveness of Today's Video Games

This is a guest post by Miles Walker, a freelance writer and blogger who usually  compares car insurance  deals over at CarinsuranceComparison.Org. His most recent review looked at the best  car insurance quotes . Video games have always held some addiction, but now more than ever that addiction is growing. People are spending more time than ever playing the games, and game designers are constantly finding new ways keep it that way. Their efforts have a been a complete success, and some games have true addicts, addicts who play 24 hours a week or more. Visual enhancements Video games have come a long way since a certain duo of Italian plumbers started showing up in people's houses in the late 1980s. By leaps and bounds, video game graphics have become alarmingly sophisticated. Each graphical improvement increased a game's possibilities and added more depth to video games. Designers began thriving on this depth, making games with more achievements, unlocks, lev...