Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions api/dev/states/shares.ini
Original file line number Diff line number Diff line change
Expand Up @@ -65,4 +65,38 @@ color="yellow-on"
size="0"
free="9091184"
used="32831348"
luksStatus="0"
["system.with.periods"]
name="system.with.periods"
nameOrig="system.with.periods"
comment="system data with periods"
allocator="highwater"
splitLevel="1"
floor="0"
include=""
exclude=""
useCache="prefer"
cachePool="cache"
cow="auto"
color="yellow-on"
size="0"
free="9091184"
used="32831348"
luksStatus="0"
["system.with.🚀"]
name="system.with.🚀"
nameOrig="system.with.🚀"
comment="system data with 🚀"
allocator="highwater"
splitLevel="1"
floor="0"
include=""
exclude=""
useCache="prefer"
cachePool="cache"
cow="auto"
color="yellow-on"
size="0"
free="9091184"
used="32831348"
luksStatus="0"
84 changes: 84 additions & 0 deletions api/src/__test__/core/utils/shares/get-shares.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,48 @@ test('Returns both disk and user shares', async () => {
"type": "user",
"used": 33619300,
},
{
"allocator": "highwater",
"cachePool": "cache",
"color": "yellow-on",
"comment": "system data with periods",
"cow": "auto",
"exclude": [],
"floor": "0",
"free": 9309372,
"id": "system.with.periods",
"include": [],
"luksStatus": "0",
"name": "system.with.periods",
"nameOrig": "system.with.periods",
"nfs": {},
"size": 0,
"smb": {},
"splitLevel": "1",
"type": "user",
"used": 33619300,
},
{
"allocator": "highwater",
"cachePool": "cache",
"color": "yellow-on",
"comment": "system data with 🚀",
"cow": "auto",
"exclude": [],
"floor": "0",
"free": 9309372,
"id": "system.with.🚀",
"include": [],
"luksStatus": "0",
"name": "system.with.🚀",
"nameOrig": "system.with.🚀",
"nfs": {},
"size": 0,
"smb": {},
"splitLevel": "1",
"type": "user",
"used": 33619300,
},
],
}
`);
Expand Down Expand Up @@ -211,6 +253,48 @@ test('Returns shares by type', async () => {
"type": "user",
"used": 33619300,
},
{
"allocator": "highwater",
"cachePool": "cache",
"color": "yellow-on",
"comment": "system data with periods",
"cow": "auto",
"exclude": [],
"floor": "0",
"free": 9309372,
"id": "system.with.periods",
"include": [],
"luksStatus": "0",
"name": "system.with.periods",
"nameOrig": "system.with.periods",
"nfs": {},
"size": 0,
"smb": {},
"splitLevel": "1",
"type": "user",
"used": 33619300,
},
{
"allocator": "highwater",
"cachePool": "cache",
"color": "yellow-on",
"comment": "system data with 🚀",
"cow": "auto",
"exclude": [],
"floor": "0",
"free": 9309372,
"id": "system.with.🚀",
"include": [],
"luksStatus": "0",
"name": "system.with.🚀",
"nameOrig": "system.with.🚀",
"nfs": {},
"size": 0,
"smb": {},
"splitLevel": "1",
"type": "user",
"used": 33619300,
},
]
`);
expect(getShares('disk')).toMatchInlineSnapshot('null');
Expand Down
Loading
Loading