Skip to content

Development Environment

Fernando Dodino edited this page Sep 21, 2024 · 3 revisions

These are the recommended coding standards & conventions

IDE

General consideration

  • we use english as primary language, although in issues you can express yourself in spanish if you feel more comfortable
  • define always good and intention-revealing names, no p, no x please!

Wollok files

  • use 2 spaces for indent, no tabs
  • declarative sentences preferred, eg. fold instead of forEach, any instead of count + length > 0
  • value objects should be considered immutable

Before opening a PR

It could be useful to verify the code in Wollok-TS implementation and run the sanity tests.

Changes could break any Wollok implementation, but at least you are sure which are the next steps.

Sanity Tests

  • we have a folder hierarchy, so you should add your in the corresponding location. If you have questions, please, join Uqbar Discord channel
  • if you are adding a new file, take your time, and explain
    • the scenario: which features do the classes/objects have. Avoid complex scenarios, split them into several files to ease maintainability.
    • tests, where they begin
  • whenever possible, avoid several asserts in the same test