added new manual tests for new methods in String
This commit is contained in:
parent
1dec4febcc
commit
c42cd20dd6
@ -1,5 +1,6 @@
|
|||||||
#include<iostream>
|
#include<iostream>
|
||||||
#include<sstream>
|
#include<sstream>
|
||||||
|
#include<cstring>
|
||||||
#include"String.h"
|
#include"String.h"
|
||||||
|
|
||||||
|
|
||||||
@ -18,5 +19,11 @@ int main()
|
|||||||
str2 = String(" tihihi");
|
str2 = String(" tihihi");
|
||||||
std::cout << str4 + str3 << std::endl;
|
std::cout << str4 + str3 << std::endl;
|
||||||
std::cout << ((str4 + str3)+=str2) << std::endl;
|
std::cout << ((str4 + str3)+=str2) << std::endl;
|
||||||
|
str4 += 'k';
|
||||||
|
std::cout << str4 << std::endl;
|
||||||
|
std::cout << str2+'k' << std::endl;
|
||||||
std::cout << str4[0] << static_cast<const String>(str2)[1] << std::endl;
|
std::cout << str4[0] << static_cast<const String>(str2)[1] << std::endl;
|
||||||
|
String str5 = str2;
|
||||||
|
str5[0] = 'i';
|
||||||
|
std::cout << str5 << std::endl;
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user