mirror of
https://github.com/actions/setup-python.git
synced 2025-08-27 03:04:14 +00:00
add mock for tests
This commit is contained in:
parent
978873d606
commit
30fcc527a5
@ -163,6 +163,12 @@ virtualenvs.path = "{cache-dir}/virtualenvs" # /Users/patrick/Library/Caches/py
|
|||||||
fileHash,
|
fileHash,
|
||||||
cachePaths
|
cachePaths
|
||||||
) => {
|
) => {
|
||||||
|
restoreCacheSpy.mockImplementation(
|
||||||
|
(cachePaths: string[], primaryKey: string, restoreKey?: string) => {
|
||||||
|
return primaryKey.includes(fileHash) ? primaryKey : '';
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
const cacheDistributor = getCacheDistributor(
|
const cacheDistributor = getCacheDistributor(
|
||||||
packageManager,
|
packageManager,
|
||||||
pythonVersion,
|
pythonVersion,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user