Skip to content

When(...).Throws gives a CouldNotSetReturnDueToNoLastCallException (#803) #164

When(...).Throws gives a CouldNotSetReturnDueToNoLastCallException (#803)

When(...).Throws gives a CouldNotSetReturnDueToNoLastCallException (#803) #164

Triggered via pull request May 27, 2024 18:04
Status Success
Total duration 4m 59s
Artifacts

build_and_test.yml

on: pull_request
test-documentation
3m 59s
test-documentation
format-verify
40s
format-verify
Matrix: test
Fit to window
Zoom out
Zoom in

Annotations

126 warnings
test (ubuntu-latest, net8.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (ubuntu-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net7.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (ubuntu-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net8.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (macOS-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net6.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (macOS-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
format-verify
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (macOS-latest, net7.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (macOS-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (macOS-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net462)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (windows-latest, net462): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net462): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net462): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net462): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net462): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net462): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net462): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net462): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net6.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (windows-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net8.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (windows-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net8.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net7.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (windows-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (windows-latest, net7.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test-documentation
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test-documentation
The field 'Tests_2010_03_01_received_calls.CommandWatcher.command' is never used
test-documentation
The field 'Tests_2010_03_01_received_calls.CommandWatcher.command' is never used
test-documentation
The field 'Tests_2010_03_01_received_calls.CommandWatcher.command' is never used
test-documentation: bin/Debug/CodeFromDocs/2010-03-01-received-calls.cs#L131
The field 'Tests_2010_03_01_received_calls.CommandWatcher.command' is never used
test-documentation
The field 'Tests_2010_03_01_received_calls.CommandWatcher.command' is never used
test-documentation
The field 'Tests_2010_03_01_received_calls.CommandWatcher.command' is never used
test-documentation
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test-documentation
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test-documentation
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test-documentation
Parameter 'arg' is unread.
test (ubuntu-latest, net6.0)
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/setup-dotnet@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
test (ubuntu-latest, net6.0)
Failed to download action 'https://api.github.com/repos/actions/setup-dotnet/tarball/3447fd6a9f9e57506b15f895c5b76d3b197dc7c2'. Error: The request was canceled due to the configured HttpClient.Timeout of 100 seconds elapsing.
test (ubuntu-latest, net6.0)
Back off 22.593 seconds before retry.
test (ubuntu-latest, net6.0)
Failed to download action 'https://api.github.com/repos/actions/setup-dotnet/tarball/3447fd6a9f9e57506b15f895c5b76d3b197dc7c2'. Error: The request was canceled due to the configured HttpClient.Timeout of 100 seconds elapsing.
test (ubuntu-latest, net6.0)
Back off 12.16 seconds before retry.
test (ubuntu-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L144
'WhenCalled<ISomething>.Throws(Func<CallInfo, Exception>)' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L88
'WhenCalled<ISomething>.Throws<TException>()' is obsolete: 'The recommended method to use is Throw().'
test (ubuntu-latest, net6.0): tests/NSubstitute.Acceptance.Specs/WhenCalledDo.cs#L116
'WhenCalled<ISomething>.Throws(Exception)' is obsolete: 'The recommended method to use is Throw().'