diff options
Diffstat (limited to 'c/test.cpp')
-rw-r--r-- | c/test.cpp | 27 |
1 files changed, 26 insertions, 1 deletions
@@ -195,6 +195,30 @@ TESTS } //DeleteFile(L"tmp.dat"); } + + TEST(DownloadData) + { + WcharPtr title, wiki, date, source, hint; + int i = 1053; + /* This is slow. */ + while(Pl("episode_data","fetch_episode_data",++i,&title,&wiki,&date,&source,&hint)) { + extern FileView<ElvDataA> g_fvElv; + extern FileView<DlvDataA> g_fvDlv; + + ElvDataA& e = g_fvElv.At(i-1); + Wcscpy(e.title, title); + if (!e.siEp[0]) + Swprintf(e.siEp, L"%d", i); + + DlvDataA& d = g_fvDlv.At(i-1); + Wcscpy(d.wiki, wiki); + Wcscpy(d.date, date); + Wcscpy(d.source, source); + Wcscpy(d.hint, hint); + } + extern CfgA& g_cfg; + g_cfg.cEp = i; + } }; int RunTests() @@ -207,7 +231,8 @@ int RunTests() //MigrateElvDataFromPrologToDisk{}, SampleConfigurationToDisk{}, //MigrateCfg{} - MigrateDlvDataFromPrologToDisk{}, + //MigrateDlvDataFromPrologToDisk{}, + //DownloadData{}, }; printf("Results (%llu tests):\n", sizeof(tests)/sizeof(*tests)); |