Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
B
boolinq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
boolinq
Commits
0fedea17
Commit
0fedea17
authored
Jun 29, 2019
by
Anton Bukov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove obsolete test file
parent
90c403d0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
95 deletions
+0
-95
ToContainerTest.cpp
test/ToContainerTest.cpp
+0
-95
No files found.
test/ToContainerTest.cpp
deleted
100644 → 0
View file @
90c403d0
#include <list>
#include <deque>
#include <vector>
#include <gtest/gtest.h>
#include "CommonTests.h"
#include "IterRange.h"
#include "ToContainer.h"
using
namespace
boolinq
;
//////////////////////////////////////////////////////////////////////////
TEST
(
ToContainer
,
Array2List
)
{
int
src
[]
=
{
100
,
200
,
300
};
auto
rng
=
range
(
src
);
auto
dst
=
toContainer
<
std
::
list
>
(
rng
);
EXPECT_EQ
(
3
,
dst
.
size
());
EXPECT_EQ
(
100
,
dst
.
front
());
dst
.
pop_front
();
EXPECT_EQ
(
200
,
dst
.
front
());
dst
.
pop_front
();
EXPECT_EQ
(
300
,
dst
.
front
());
dst
.
pop_front
();
}
TEST
(
ToContainer
,
Array2Deque
)
{
int
src
[]
=
{
100
,
200
,
300
};
auto
rng
=
range
(
src
);
auto
dst
=
toContainer
<
std
::
deque
>
(
rng
);
EXPECT_EQ
(
3
,
dst
.
size
());
EXPECT_EQ
(
100
,
dst
.
front
());
dst
.
pop_front
();
EXPECT_EQ
(
200
,
dst
.
front
());
dst
.
pop_front
();
EXPECT_EQ
(
300
,
dst
.
front
());
dst
.
pop_front
();
}
TEST
(
ToContainer
,
Array2Vector
)
{
int
src
[]
=
{
100
,
200
,
300
};
auto
rng
=
range
(
src
);
auto
dst
=
toContainer
<
std
::
vector
>
(
rng
);
EXPECT_EQ
(
3
,
dst
.
size
());
EXPECT_EQ
(
100
,
dst
[
0
]);
EXPECT_EQ
(
200
,
dst
[
1
]);
EXPECT_EQ
(
300
,
dst
[
2
]);
}
//////////////////////////////////////////////////////////////////////////
TEST
(
ToContainer
,
List2List
)
{
std
::
list
<
int
>
src
;
src
.
push_back
(
100
);
src
.
push_back
(
200
);
src
.
push_back
(
300
);
auto
rng
=
range
(
src
);
auto
dst
=
toContainer
<
std
::
list
>
(
rng
);
EXPECT_EQ
(
dst
,
src
);
}
TEST
(
ToContainer
,
Deque2Deque
)
{
std
::
deque
<
int
>
src
;
src
.
push_back
(
100
);
src
.
push_back
(
200
);
src
.
push_back
(
300
);
auto
rng
=
range
(
src
);
auto
dst
=
toContainer
<
std
::
deque
>
(
rng
);
EXPECT_EQ
(
dst
,
src
);
}
TEST
(
ToContainer
,
Vector2Vector
)
{
std
::
vector
<
int
>
src
;
src
.
push_back
(
100
);
src
.
push_back
(
200
);
src
.
push_back
(
300
);
auto
rng
=
range
(
src
);
auto
dst
=
toContainer
<
std
::
vector
>
(
rng
);
EXPECT_EQ
(
dst
,
src
);
}
//////////////////////////////////////////////////////////////////////////
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment