int main(int argc, const char **argv) { printf("Running all tests...\n\n"); int err; if ((err = setjmp(G_err))) { printf("ERROR: %d\n",err); } else { def_sys(); //**** core tests testDef(); testTree(); testMTree(); testStream(); testLabel(); testSemtrex(); testReceptor(); testProcess(); testScape(); testVMHost(); testAccumulator(); //***** examples testProfileExample(); testHTTPExample(); sys_free(); report_tests(); } pthread_exit(NULL); // return 0; }
int main(int argc, const char **argv) { printf("Running all tests...\n\n"); //**** core tests testTree(); testParse(); testDef(); testWord(); testFlow(); testVM(); testStack(); testInit(); testCommand(); testConversation(); testScape(); // testThreads(); //**** builtins tests testNoun(); testPattern(); //testArray(); // testStream(); testInt(); testStr255(); testCfunc(); testReceptorUtil(); // testReceptor(); //testVmHost(); //**** examples test testPoint(); // testLine(); report_tests(); return 0; }
int main(int argc, const char **argv) { printf("Running all tests...\n\n"); int err; if ((err = setjmp(G_err))) { printf("ERROR: %d\n",err); } else { G_sem = def_sys(); load_contexts(G_sem); //**** core tests testSemTable(); testDef(); testTree(); testMTree(); testStream(); testLabel(); testSemtrex(); testProcess(); testReceptor(); testScape(); testVMHost(); testAccumulator(); testProtocol(); /**** receptor tests */ /* /\* testGroup(); *\/ */ testHTTP(); /****** examples */ /* testProfileExample(); */ sys_free(G_sem); report_tests(); } pthread_exit(NULL); // return 0; }
/** * @fn SceneCreateMGridExperiment3GFlip() * * @brief Creates a multi-grid experimental scene * * @return Pointer to the created scene */ CFlux2DScene* SceneCreateMGridExperiment3GFlip() { CFlux2DScene* pScene = NULL; // Create the test definition CSceneDef testDef( L"data/hm_cape.bmp" , -5.0f, 5.0f, 256.0f, 256.0f ); // Load the test scene definition CFlux2DSceneDef scnDef; if (!LoadScnDefFromBitmap(testDef, scnDef)) { return NULL; } // Create the scene pScene = new (UseOwnMem) CFlux2DScene(3); // Add grids for left, top, and bottom int X0=64; int leftGrid = pScene->AddGrid(scnDef, X0, 256, CRegion(0.0f, 0.0f, (float)X0, 256.0f)); int rightTopGrid = pScene->AddGrid(scnDef, (256-X0)/2, (128)/2, CRegion((float)X0, 0.0f, 256.0f, 128.0f)); int rightBtmGrid = pScene->AddGrid(scnDef, 256-X0, 128, CRegion((float)X0, 128.0f, 256.0f, 256.0f)); // Calculate the bounding box pScene->CalculateBoundingRegion(); CSeamData* pSD; // Add a horizontal seam pSD = &(pScene->m_SeamArray.Append()); pSD->GridTop = rightTopGrid; pSD->GridBottom = rightBtmGrid; pSD->GridLeft = -1; pSD->GridRight = -1; // Add a vertical seam pSD = &(pScene->m_SeamArray.Append()); pSD->GridTop = -1; pSD->GridBottom = -1; pSD->GridLeft = leftGrid; pSD->GridRight = rightTopGrid; // Add second vertical seam pSD = &(pScene->m_SeamArray.Append()); pSD->GridTop = -1; pSD->GridBottom = -1; pSD->GridLeft = leftGrid; pSD->GridRight = rightBtmGrid; // Add border conditions & initialize // To the top-right part CFlux2DGrid *pF = pScene->GetGrid(rightTopGrid); pF->ResetToZeroState(); pF->AddAction(new (UseOwnMem) CFlux2DBCCopy(CFlux2DBCCopy::TOP)); pF->AddAction(new (UseOwnMem) CFlux2DBCCopy(CFlux2DBCCopy::RIGHT)); // To the bottom-right part pF = pScene->GetGrid(rightBtmGrid); pF->ResetToZeroState(); pF->AddAction(new (UseOwnMem) CFlux2DBCCopy(CFlux2DBCCopy::BOTTOM)); pF->AddAction(new (UseOwnMem) CFlux2DBCCopy(CFlux2DBCCopy::RIGHT)); // To the left part pF = pScene->GetGrid(leftGrid); pF->ResetToZeroState(); pF->AddAction(new (UseOwnMem) CFlux2DBCCopy(CFlux2DBCCopy::TOP)); pF->AddAction(new (UseOwnMem) CFlux2DBCCopy(CFlux2DBCCopy::BOTTOM)); pF->AddAction(new (UseOwnMem) CFlux2DBCSineWaveGenVerticalLeft(2.5f, 1.7f, 0.0f)); //CFlux2DAddBC_CopyRt(*pF); (DEPRECATED) return pScene; }