Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unit Test Some Things #6

Open
2 of 3 tasks
wraybowling opened this issue Aug 25, 2020 · 1 comment
Open
2 of 3 tasks

Unit Test Some Things #6

wraybowling opened this issue Aug 25, 2020 · 1 comment
Milestone

Comments

@wraybowling
Copy link
Member

wraybowling commented Aug 25, 2020

The grid and the clock code are becoming very complex. It would be good to write some unit tests so I know that it's actually doing what it's supposed to do instead of manipulating the main.cpp program or taking over the blinking LEDs all the time

  • Research the PlatformIO Unit Testing Solution
  • rewrite the platformio.ini file so that building all environments pass
  • make some new issues to address tests that need to be made
wraybowling added a commit that referenced this issue Aug 25, 2020
@wraybowling
Copy link
Member Author

I tried to understand the PIO testing stuff last week and it never worked right. There are some examples in the repo now, but it's not wired up because the tests fail on stupid things. For example, the Tri-ger does not have Serial so I cannot use Serial debugging. Fine. Can I just test the pure C++ functions? In theory, yes, but in practice no. It seems different libraries are imported in the "desktop environment" so that the tests can't even build properly, usually complaining about trying to import Arduino.h or some other standard library that works just fine when I build for the embedded hardware. There are forums where folks bump into similar problems but are harassed by neckbeards that utter the least helpful words in the history of forum replies ever "why would you ever want to do X?" So for the moment, I think that I will not worry about unit testing. It would have been really really helpful in debugging all of that very complicated clock code, all the grid stuff, all the memory problems I was trying to solve for days... But those ships have sailed now. No thanks to PIO's Unit Testing. :|

wraybowling added a commit that referenced this issue Sep 18, 2020
but now regular builds won't upload which is super annoying
wraybowling added a commit that referenced this issue Sep 26, 2020
Apparently whitespace counts as part of the string unless you use a new line so pIO couldn't read from the path with a space in front
@wraybowling wraybowling added this to the Alpha 2 milestone Sep 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant