< Summary - Kestrun — Combined Coverage

Information
Class: Public.Tasks.Get-KrTaskState
Assembly: Kestrun.PowerShell.Public
File(s): /home/runner/work/Kestrun/Kestrun/src/PowerShell/Kestrun/Public/Tasks/Get-KrTaskState.ps1
Tag: Kestrun/Kestrun@2d87023b37eb91155071c91dd3d6a2eeb3004705
Line coverage
0%
Covered lines: 0
Uncovered lines: 2
Coverable lines: 2
Total lines: 33
Line coverage: 0%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Coverage history

Coverage history 0 25 50 75 100 10/15/2025 - 01:01:18 Line coverage: 0% (0/2) Total lines: 33 Tag: Kestrun/Kestrun@7c4ce528870211ad6c2d2398c31ec13097fc5840

Metrics

File(s)

/home/runner/work/Kestrun/Kestrun/src/PowerShell/Kestrun/Public/Tasks/Get-KrTaskState.ps1

#LineLine coverage
 1<#
 2.SYNOPSIS
 3    Gets the state of a task by id.
 4.DESCRIPTION
 5    Returns the task state string for the specified task id.
 6.PARAMETER Server
 7    The Kestrun server instance.
 8.PARAMETER Id
 9    Task id to query.
 10.EXAMPLE
 11    Get-KrTaskState -Id 'task-id'
 12    Returns the state of the specified task as a [Kestrun.Tasks.TaskState] object.
 13.OUTPUTS
 14    [Kestrun.Tasks.TaskState]
 15#>
 16function Get-KrTaskState {
 17    [KestrunRuntimeApi('Everywhere')]
 18    [CmdletBinding(defaultParameterSetName = 'Default')]
 19    [OutputType([Kestrun.Tasks.TaskState])]
 20    param(
 21        [Parameter(ValueFromPipeline = $true)]
 22        [Kestrun.Hosting.KestrunHost]$Server,
 23
 24        [Parameter(mandatory = $true)]
 25        [string]$Id
 26    )
 27    begin {
 028        $Server = Resolve-KestrunServer -Server $Server
 29    }
 30    process {
 031        return $Server.Tasks.GetState($Id)
 32    }
 33}

Methods/Properties

Get-KrTaskState()