File: ConstVarList.cpp

package info (click to toggle)
hyprutils 0.11.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 560 kB
  • sloc: cpp: 5,332; sh: 10; makefile: 3
file content (15 lines) | stat: -rw-r--r-- 397 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#include <hyprutils/string/ConstVarList.hpp>

#include <gtest/gtest.h>

using namespace Hyprutils::String;

TEST(String, constvarlist) {
    CConstVarList listConst("hello    world!", 0, 's', true);
    EXPECT_EQ(listConst[0], "hello");
    EXPECT_EQ(listConst[1], "world!");

    CConstVarList listConst2("0 set", 2, ' ');
    EXPECT_EQ(listConst2[0], "0");
    EXPECT_EQ(listConst2[1], "set");
}