Skip to content

Commit fca9110

Browse files
committed
Fix unit tests
1 parent 3cdce11 commit fca9110

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

src/xtd.core/include/xtd/io/memory_stream.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,11 @@ namespace xtd {
6161
/// @brief Gets a value indicating whether the current stream supports reading.
6262
/// @return `true` if the stream supports reading; otherwise, `false`.
6363
bool can_read() const noexcept;
64+
6465
/// @brief Gets a value indicating whether the current stream supports seeking.
6566
/// @return `true` if the stream supports seeking; otherwise, `false`.
6667
bool can_seek() const noexcept;
68+
6769
/// @brief Gets a value indicating whether the current stream supports writing.
6870
/// @return `true` if the stream supports writing; otherwise, `false`.
6971
bool can_write() const noexcept;

tests/xtd.core.unit_tests/src/xtd/io/tests/seek_origin_tests.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,19 @@ using namespace xtd::tunit;
1010
namespace xtd::tests {
1111
class test_class_(seek_origin_tests) {
1212
void test_method_(begin) {
13-
assert::are_equal(1, enum_object<>::to_int32(seek_origin::begin));
13+
assert::are_equal(0, enum_object<>::to_int32(seek_origin::begin));
1414
assert::are_equal("begin", enum_object<>::to_string(seek_origin::begin));
1515
assert::are_equal(seek_origin::begin, enum_object<>::parse<seek_origin>("begin"));
1616
}
1717

1818
void test_method_(current) {
19-
assert::are_equal(2, enum_object<>::to_int32(seek_origin::current));
19+
assert::are_equal(1, enum_object<>::to_int32(seek_origin::current));
2020
assert::are_equal("current", enum_object<>::to_string(seek_origin::current));
2121
assert::are_equal(seek_origin::current, enum_object<>::parse<seek_origin>("current"));
2222
}
2323

2424
void test_method_(end) {
25-
assert::are_equal(3, enum_object<>::to_int32(seek_origin::end));
25+
assert::are_equal(2, enum_object<>::to_int32(seek_origin::end));
2626
assert::are_equal("end", enum_object<>::to_string(seek_origin::end));
2727
assert::are_equal(seek_origin::end, enum_object<>::parse<seek_origin>("end"));
2828
}

0 commit comments

Comments
 (0)