Skip to content

test(base): cover String/CString API, fix String::pop_front - #5

Closed
mmeadows20 wants to merge 1 commit into
vlad441:mainfrom
mmeadows20:fix-bounty-1
Closed

mmeadows20 wants to merge 1 commit into
vlad441:mainfrom
mmeadows20:fix-bounty-1

Conversation

@mmeadows20

@mmeadows20 mmeadows20 commented Oct 23, 2026 •

Copy link
Copy Markdown

Resolves #1

Verification

Built and ran the project's own test suite locally:

$ cd tests && bash make_test.sh
Build time: 5 sec.

$ ./tests
==== Tests Complete ==== �[0m(Time: �[33m87.200�[0m msec)
�[0m Tested|(Passed/Fail): �[33m190�[0m | (�[32m190�[0m/�[31m0�[0m); Errors|Warnings: �[31m0�[0m | �[33m0�[0m

Adds positive, negative and edge-case coverage for the documented
String and CString types of the Base module (constructors, assignment,
reserve/resize, push/pop family, erase, search helpers, startsWith/
endsWith, slice/substr, split/splitTokens/splitParts, replace/replaceAll,
case conversion, trim, toBool, operators and conversions) using only the
existing tests.cpp runner macros and the C/C++ standard library.

Writing the pop_front() test exposed a bug: erase((size_t)0) defaulted
len to NPOS, which is clamped to _len-pos, so pop_front() dropped the
whole string instead of the first character. Fixed to erase(0, 1);
Buffer::pop_front() already behaved correctly.
@vlad441

vlad441 commented Oct 23, 2026

Copy link
Copy Markdown
Owner

Закрыто в связи с несоответствием правилам внесения изменений (автоматически сгенерированный/несогласованный PR). Пожалуйста, ознакомьтесь с условиями задачи.

@vlad441 vlad441 closed this Oct 23, 2026
@mmeadows20
mmeadows20 deleted the fix-bounty-1 branch October 25, 2026 22:34
vlad441 added a commit that referenced this pull request Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Задача: Дописать тесты

2 participants