Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
TestNfsFile.cpp File Reference
#include "URL.h"
#include "filesystem/NFSFile.h"
#include "test/TestUtils.h"
#include <errno.h>
#include <string>
#include <gtest/gtest.h>

Classes

struct  SplitPath
 
class  TestNfs
 
class  ExportList
 

Functions

 TEST_P (TestNfs, splitUrlIntoExportAndPath)
 
 INSTANTIATE_TEST_SUITE_P (NfsFile, TestNfs, ValuesIn(g_TestData))
 

Variables

struct SplitPath g_TestData []
 

Function Documentation

◆ INSTANTIATE_TEST_SUITE_P()

INSTANTIATE_TEST_SUITE_P ( NfsFile ,
TestNfs ,
ValuesIn(g_TestData)  )

◆ TEST_P()

TEST_P ( TestNfs ,
splitUrlIntoExportAndPath  )

Variable Documentation

◆ g_TestData

struct SplitPath g_TestData[]
Initial value:
= {
{"nfs://192.168.0.1:2049/srv/test/tvmedia/foo.txt", "/srv/test", "//tvmedia/foo.txt", true, true},
{"nfs://192.168.0.1/srv/test/tv/media/foo.txt", "/srv/test/tv", "//media/foo.txt", true, true},
{"nfs://192.168.0.1:2049/srv/test/tvmedia", "/srv/test", "//tvmedia", true, true},
{"nfs://192.168.0.1:2049/srv/test/tvmedia/", "/srv/test", "//tvmedia/", true, true},
{"nfs://192.168.0.1:2049/srv/test/tv/media", "/srv/test/tv", "//media", true, true},
{"nfs://192.168.0.1:2049/srv/test/tv/media/", "/srv/test/tv", "//media/", true, true},
{"nfs://192.168.0.1:2049/srv/test/tv", "/srv/test/tv", "//", true, true},
{"nfs://192.168.0.1:2049/srv/test/", "/srv/test", "//", true, true},
{"nfs://192.168.0.1:2049/", "/", "//", true, true},
{"nfs://192.168.0.1:2049/notexported/foo.txt", "/", "//notexported/foo.txt", true, true},
{"nfs://192.168.0.1:2049/notexported/foo.txt", "/notexported", "//foo.txt", false, false},
}