#include #include "test.h" #include "beatmap.h" //tests int difficulties_test(); int characteristics_test(); test_t tests[] = { difficulties_test, characteristics_test, NULL}; int main(int argc, char** argv) { test_t* current = tests; int failcount = 0; int testcount = 0; for(; *current; current++) { testcount++; printf("\033[1mRunning test number: %d ", testcount); if((*current)()) { printf("\033[1;92msucceeded\033[0;1m!\n"); } else { printf("\033[1;91mfailed\033[0;1m\n"); failcount++; } } printf("\033[1;93m%d\033[0;1m/%d failed\n", failcount, testcount); //simple read test std::unique_ptr bmap = Beatsaber::BeatMap::loadFromFolder("/media/satassd/steam/steamapps/common/Beat Saber/Beat Saber_Data/CustomLevels/1dd (Portal - Still Alive (Uppermost Remix) - kryptikos)"); if(!bmap) std::cout << "Could not load File" << std::endl; else bmap->printDebug(); return failcount > 0; }