January 27, 2020

Treesque -- A new name for a first project

Since my last post, I kept working on this new project, and made quite a good progress. So let’s welcome Treesque ! Go take a look, and give it a try. And if you like it, let me know on Twitter or by email. It is very basic at this point, missing a lot of functionalities, but it is a start, and I am happy to just have something out. Read more

March 21, 2019

My simplified development workflow in Go

Using tests during development to keep you code tidy As I was working on a project, while developing a new function, I noticed that I was modifying some existing code to be able to test it. Doing it this way seemed like a very bad idea, so I looked for a better way to do it. But let’s start an insanely simple example, to clarify what I’m saying. We start with a basic program, an extraString function and a main. Read more

September 12, 2018

Testing Rest API Responses

I have been developping a REST API at work using Flask, and wanted to test the response I got. I started by testing directly the raw response using response.data, which works for small responses. As soon as you want to make it dynamic, it becomes a nightmare. Let’s say we start with the following test # Bad idea def test_response_string(): response = client.get("/test") assert response.status_code == 200 assert response.data == '{"key1": "value1", "key2": "value2"}' Now, with just this test, adding a value or modifying it would be easy. Read more

Copyright Marin Gilles 2019-2022