28 lines
467 B
C++
28 lines
467 B
C++
#include <iostream>
|
|
#include "of_str.h"
|
|
#include <of_path.h>
|
|
#include <cassert>
|
|
|
|
using namespace ofen;
|
|
|
|
void testA()
|
|
{
|
|
assert(COfPath::is_same_path(ofT("D:/Java"), ofT("D:\\Java\\")));
|
|
}
|
|
|
|
void testB()
|
|
{
|
|
auto home = COfPath::get_home();
|
|
assert(!home.empty());
|
|
|
|
auto rp = COfStr::replace(ofT("cpp/z"), ofT("p/"), ofT("Ni"));
|
|
assert(rp == ofT("cpNiz"));
|
|
}
|
|
|
|
int main()
|
|
{
|
|
testA();
|
|
testB();
|
|
std::cout << "Done" << std::endl;
|
|
return 0;
|
|
} |