mirror of
https://code.forgejo.org/actions/setup-python
synced 2025-06-08 04:18:19 +02:00
Initial pass
This commit is contained in:
commit
39c08a0eaa
7242 changed files with 1886006 additions and 0 deletions
40
__tests__/finder.test.ts
Normal file
40
__tests__/finder.test.ts
Normal file
|
@ -0,0 +1,40 @@
|
|||
import io = require('@actions/io');
|
||||
import fs = require('fs');
|
||||
import os = require('os');
|
||||
import path = require('path');
|
||||
|
||||
const toolDir = path.join(
|
||||
process.cwd(),
|
||||
'runner',
|
||||
path.join(
|
||||
Math.random()
|
||||
.toString(36)
|
||||
.substring(7)
|
||||
),
|
||||
'tools'
|
||||
);
|
||||
const tempDir = path.join(
|
||||
process.cwd(),
|
||||
'runner',
|
||||
path.join(
|
||||
Math.random()
|
||||
.toString(36)
|
||||
.substring(7)
|
||||
),
|
||||
'temp'
|
||||
);
|
||||
|
||||
process.env['RUNNER_TOOLSDIRECTORY'] = toolDir;
|
||||
process.env['RUNNER_TEMPDIRECTORY'] = tempDir;
|
||||
|
||||
import * as finder from '../src/find-python';
|
||||
|
||||
describe('Finder tests', () => {
|
||||
it('Finds Python if it is installed', async () => {});
|
||||
|
||||
it('Errors if Python is not installed', async () => {});
|
||||
|
||||
it('Finds PyPy if it is installed', async () => {});
|
||||
|
||||
it('Errors if PyPy is not installed', async () => {});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue