4
10 Comments

Do you use any testing framework?

Hi Hackers,

I was looking for a solution that would help manage all the unit and integration tests.
Cucumber is apparently the most used framework but I don't understand the hype. Its language gherkin does not automate the tests, so it just feels like more work.

Is anyone using a useful framework or solution that can integrate with gitlab/github for CI?

Thanks

posted to Icon for group Developers
Developers
on January 27, 2020
  1. 2

    I use Pytest and for front end I'd consider Cypress.

  2. 2

    I use super test for api endpoints

    Then for the front end use puppeteer. There’s a github repo & chrome extension called puppeteer recorder, that records ur mouse and turns it into puppeteer code. I usually use that then tweak the code it exports manually.

    1. 1

      Interesting. Does puppeteer work for mobile apps as well?

      1. 1

        Nope puppeteer uses chromium under the hood.

        Also puppeteer recorded was made by ChecklyHQ, which has a easy to use paid testing service

  3. 2

    I've ended up building my own.

    Backend & microservices: I've written a JS function that I pass the URL, arguments as JSON, and expected result as JSON. It then outputs the details with a red H1 if the test failed or green if it passed. It's then really easy to quickly go through tests and see what tests are failing and why.

    Front-end: I write code comments as JSON that can easily be parsed out. It's then very easy to display all QA tests for each UI and confirm they are all working.

    My big pet peeve with a lot of the testing frameworks out there 7s that the tests are defined/documented separate from the code so it becomes very hard for a dev to see what tests the code is expected to pass.

    Hope that helps,

    1. 1

      Thanks Simon.
      I was considering using the CI of gitlab for all the automated unit and integration tests and maintain a spreadsheet for all the manual tests.

      Actually I think it's a good practice to document the tests outside the codebase. Otherwise it will be very hard for anyone who didn't build the tech to understand where to look.

  4. 2

    Are you testing a server or a user interface? Both? What languages are you working with?

    1. 1

      I'm testing both and using dart.

      1. 1

        I'm not familiar with dart or the details of your situation, and I'm biased in my full stack JavaScript background, but you can get a decent bit of coverage with End-to-End tests using a tool like Cypress (or Selenium, Puppeteer, Nightwatch, etc.). It's very easy to get tests going quickly.

        For api testing you could use something like Postman.

        I'm sure you'd be able to figure out CI integrations with all of those - I know I've gotten Cypress and CircleCI working.

        1. 1

          Postman is definitely a great tool for APIs.
          I never tried Selenium but I heard it can cover a wide range of tests. Will have a look. Thanks ;)

Trending on Indie Hackers
I spent $0 on marketing and got 1,200 website visitors - Here's my exact playbook User Avatar 58 comments Veo 3.1 vs Sora 2: AI Video Generation in 2025 🎬🤖 User Avatar 27 comments Codenhack Beta — Full Access + Referral User Avatar 21 comments I built eSIMKitStore — helping travelers stay online with instant QR-based eSIMs 🌍 User Avatar 20 comments 🚀 Get Your Brand Featured on FaceSeek User Avatar 18 comments Day 6 - Slow days as a solo founder User Avatar 16 comments