Fix informational and debug messages

This commit is contained in:
IvanZosimov
2023-05-18 12:39:22 +02:00
parent 3cf3e230c1
commit 38b49fb717
5 changed files with 17 additions and 19 deletions

View File

@ -59,7 +59,7 @@ describe('setup-dotnet tests', () => {
const expectedDebugMessage =
'No version found, trying to find version from global.json';
const expectedInfoMessage = `global.json wasn't found in the root directory. No .NET version will be installed.`;
const expectedInfoMessage = `A global.json wasn't found in the root directory. No .NET version will be installed.`;
await setup.run();
@ -73,7 +73,7 @@ describe('setup-dotnet tests', () => {
inputs['dotnet-version'] = ['6.0'];
inputs['dotnet-quality'] = 'fictitiousQuality';
const expectedErrorMessage = `${inputs['dotnet-quality']} is not a supported value for 'dotnet-quality' option. Supported values are: daily, signed, validated, preview, ga.`;
const expectedErrorMessage = `Value '${inputs['dotnet-quality']}' is not supported for the 'dotnet-quality' option. Supported values are: daily, signed, validated, preview, ga.`;
await setup.run();
expect(setFailedSpy).toHaveBeenCalledWith(expectedErrorMessage);
@ -160,7 +160,7 @@ describe('setup-dotnet tests', () => {
it(`shouldn't call setOutput() if actions didn't install .NET`, async () => {
inputs['dotnet-version'] = [];
const warningMessage = `No .NET version was installed. The 'dotnet-version' output will not be set.`;
const warningMessage = `The 'dotnet-version' output will not be set.`;
addToPathSpy.mockImplementation(() => {});