mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Refine get_hds_fragment and get_hds_window in time unit
This commit is contained in:
parent
917f6d066d
commit
010e35bec2
4 changed files with 23 additions and 14 deletions
|
@ -1879,6 +1879,16 @@ VOID TEST(ConfigUnitTest, CheckDefaultValuesVhost)
|
|||
EXPECT_EQ(30 * SRS_UTIME_SECONDS, conf.get_hls_window("v"));
|
||||
}
|
||||
|
||||
if (true) {
|
||||
EXPECT_TRUE(ERROR_SUCCESS == conf.parse(_MIN_OK_CONF));
|
||||
EXPECT_EQ(10 * SRS_UTIME_SECONDS, conf.get_hds_fragment(""));
|
||||
EXPECT_EQ(60 * SRS_UTIME_SECONDS, conf.get_hds_window(""));
|
||||
|
||||
EXPECT_TRUE(ERROR_SUCCESS == conf.parse(_MIN_OK_CONF"vhost v{hds{hds_fragment 20;hds_window 30;}}"));
|
||||
EXPECT_EQ(20 * SRS_UTIME_SECONDS, conf.get_hds_fragment("v"));
|
||||
EXPECT_EQ(30 * SRS_UTIME_SECONDS, conf.get_hds_window("v"));
|
||||
}
|
||||
|
||||
if (true) {
|
||||
EXPECT_TRUE(ERROR_SUCCESS == conf.parse(_MIN_OK_CONF));
|
||||
EXPECT_EQ(30 * SRS_UTIME_SECONDS, conf.get_queue_length(""));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue