mirror of
https://github.com/ivuorinen/hiha-arvio.git
synced 2026-03-06 18:58:25 +00:00
feat: project setup and core models with TDD
MILESTONE 1 COMPLETE: Project Setup: - Create .NET 8 MAUI solution targeting iOS, macOS, and web - Configure nullable reference types and warnings as errors - Add required dependencies (MAUI 8.0.3, SQLite, CommunityToolkit.Mvvm) - Add testing dependencies (xUnit, NSubstitute, FluentAssertions, Coverlet) - Create comprehensive .editorconfig with C# coding standards - Update CLAUDE.md with development commands Core Models (TDD - 48 tests, all passing): - EstimateMode enum (Work, Generic, Humorous modes) - EstimateResult model with validation (intensity 0.0-1.0, non-null text) - ShakeData model with intensity validation - AppSettings model with defaults (Work mode, max history 10) Build Status: - All platforms build successfully (net8.0, iOS, macOS) - 0 warnings, 0 errors - Test coverage: 51.28% line, 87.5% branch (models have ~100% coverage) Per spec: Strict TDD followed (RED-GREEN-REFACTOR), models fully validated 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
33
tests/HihaArvio.Tests/HihaArvio.Tests.csproj
Normal file
33
tests/HihaArvio.Tests/HihaArvio.Tests.csproj
Normal file
@@ -0,0 +1,33 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
|
||||
<IsPackable>false</IsPackable>
|
||||
<IsTestProject>true</IsTestProject>
|
||||
|
||||
<!-- Per spec: treat warnings as errors, C# 12 -->
|
||||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
|
||||
<LangVersion>12</LangVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="coverlet.collector" Version="6.0.0" />
|
||||
<PackageReference Include="FluentAssertions" Version="8.8.0" />
|
||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
|
||||
<PackageReference Include="NSubstitute" Version="5.3.0" />
|
||||
<PackageReference Include="xunit" Version="2.5.3" />
|
||||
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.3" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Using Include="Xunit" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\src\HihaArvio\HihaArvio.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
90
tests/HihaArvio.Tests/Models/AppSettingsTests.cs
Normal file
90
tests/HihaArvio.Tests/Models/AppSettingsTests.cs
Normal file
@@ -0,0 +1,90 @@
|
||||
using FluentAssertions;
|
||||
using HihaArvio.Models;
|
||||
|
||||
namespace HihaArvio.Tests.Models;
|
||||
|
||||
public class AppSettingsTests
|
||||
{
|
||||
[Fact]
|
||||
public void AppSettings_DefaultConstructor_ShouldSetWorkModeAsDefault()
|
||||
{
|
||||
// Act
|
||||
var settings = new AppSettings();
|
||||
|
||||
// Assert
|
||||
settings.SelectedMode.Should().Be(EstimateMode.Work);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void AppSettings_DefaultConstructor_ShouldSetMaxHistorySizeTo10()
|
||||
{
|
||||
// Act
|
||||
var settings = new AppSettings();
|
||||
|
||||
// Assert
|
||||
settings.MaxHistorySize.Should().Be(10);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(EstimateMode.Work)]
|
||||
[InlineData(EstimateMode.Generic)]
|
||||
[InlineData(EstimateMode.Humorous)]
|
||||
public void AppSettings_ShouldAllowModeChanges(EstimateMode mode)
|
||||
{
|
||||
// Arrange
|
||||
var settings = new AppSettings();
|
||||
|
||||
// Act
|
||||
settings.SelectedMode = mode;
|
||||
|
||||
// Assert
|
||||
settings.SelectedMode.Should().Be(mode);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(1)]
|
||||
[InlineData(5)]
|
||||
[InlineData(10)]
|
||||
[InlineData(50)]
|
||||
[InlineData(100)]
|
||||
public void AppSettings_ShouldAcceptValidMaxHistorySizeValues(int size)
|
||||
{
|
||||
// Arrange
|
||||
var settings = new AppSettings();
|
||||
|
||||
// Act
|
||||
settings.MaxHistorySize = size;
|
||||
|
||||
// Assert
|
||||
settings.MaxHistorySize.Should().Be(size);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(0)]
|
||||
[InlineData(-1)]
|
||||
[InlineData(-10)]
|
||||
public void AppSettings_ShouldThrowForInvalidMaxHistorySize(int invalidSize)
|
||||
{
|
||||
// Arrange
|
||||
var settings = new AppSettings();
|
||||
|
||||
// Act
|
||||
Action act = () => settings.MaxHistorySize = invalidSize;
|
||||
|
||||
// Assert
|
||||
act.Should().Throw<ArgumentOutOfRangeException>()
|
||||
.WithMessage("*must be greater than 0*");
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void AppSettings_ShouldCreateWithDefaultValues()
|
||||
{
|
||||
// Act
|
||||
var settings = new AppSettings();
|
||||
|
||||
// Assert
|
||||
settings.Should().NotBeNull();
|
||||
settings.SelectedMode.Should().Be(EstimateMode.Work);
|
||||
settings.MaxHistorySize.Should().Be(10);
|
||||
}
|
||||
}
|
||||
51
tests/HihaArvio.Tests/Models/EstimateModeTests.cs
Normal file
51
tests/HihaArvio.Tests/Models/EstimateModeTests.cs
Normal file
@@ -0,0 +1,51 @@
|
||||
using FluentAssertions;
|
||||
using HihaArvio.Models;
|
||||
|
||||
namespace HihaArvio.Tests.Models;
|
||||
|
||||
public class EstimateModeTests
|
||||
{
|
||||
[Fact]
|
||||
public void EstimateMode_ShouldHaveWorkValue()
|
||||
{
|
||||
// Act
|
||||
var mode = EstimateMode.Work;
|
||||
|
||||
// Assert
|
||||
mode.Should().Be(EstimateMode.Work);
|
||||
((int)mode).Should().Be(0);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void EstimateMode_ShouldHaveGenericValue()
|
||||
{
|
||||
// Act
|
||||
var mode = EstimateMode.Generic;
|
||||
|
||||
// Assert
|
||||
mode.Should().Be(EstimateMode.Generic);
|
||||
((int)mode).Should().Be(1);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void EstimateMode_ShouldHaveHumorousValue()
|
||||
{
|
||||
// Act
|
||||
var mode = EstimateMode.Humorous;
|
||||
|
||||
// Assert
|
||||
mode.Should().Be(EstimateMode.Humorous);
|
||||
((int)mode).Should().Be(2);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void EstimateMode_ShouldHaveExactlyThreeValues()
|
||||
{
|
||||
// Act
|
||||
var values = Enum.GetValues<EstimateMode>();
|
||||
|
||||
// Assert
|
||||
values.Should().HaveCount(3);
|
||||
values.Should().Contain(new[] { EstimateMode.Work, EstimateMode.Generic, EstimateMode.Humorous });
|
||||
}
|
||||
}
|
||||
147
tests/HihaArvio.Tests/Models/EstimateResultTests.cs
Normal file
147
tests/HihaArvio.Tests/Models/EstimateResultTests.cs
Normal file
@@ -0,0 +1,147 @@
|
||||
using FluentAssertions;
|
||||
using HihaArvio.Models;
|
||||
|
||||
namespace HihaArvio.Tests.Models;
|
||||
|
||||
public class EstimateResultTests
|
||||
{
|
||||
[Fact]
|
||||
public void EstimateResult_ShouldCreateWithAllProperties()
|
||||
{
|
||||
// Arrange
|
||||
var id = Guid.NewGuid();
|
||||
var timestamp = DateTimeOffset.UtcNow;
|
||||
var estimateText = "2 weeks";
|
||||
var mode = EstimateMode.Work;
|
||||
var intensity = 0.75;
|
||||
var duration = TimeSpan.FromSeconds(5);
|
||||
|
||||
// Act
|
||||
var result = new EstimateResult
|
||||
{
|
||||
Id = id,
|
||||
Timestamp = timestamp,
|
||||
EstimateText = estimateText,
|
||||
Mode = mode,
|
||||
ShakeIntensity = intensity,
|
||||
ShakeDuration = duration
|
||||
};
|
||||
|
||||
// Assert
|
||||
result.Id.Should().Be(id);
|
||||
result.Timestamp.Should().Be(timestamp);
|
||||
result.EstimateText.Should().Be(estimateText);
|
||||
result.Mode.Should().Be(mode);
|
||||
result.ShakeIntensity.Should().Be(intensity);
|
||||
result.ShakeDuration.Should().Be(duration);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(0.0)]
|
||||
[InlineData(0.3)]
|
||||
[InlineData(0.7)]
|
||||
[InlineData(1.0)]
|
||||
public void EstimateResult_ShouldAcceptValidIntensityValues(double intensity)
|
||||
{
|
||||
// Act
|
||||
var result = new EstimateResult { ShakeIntensity = intensity };
|
||||
|
||||
// Assert
|
||||
result.ShakeIntensity.Should().Be(intensity);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(-0.1)]
|
||||
[InlineData(1.1)]
|
||||
[InlineData(2.0)]
|
||||
public void EstimateResult_ShouldThrowForInvalidIntensity(double invalidIntensity)
|
||||
{
|
||||
// Act
|
||||
Action act = () => _ = new EstimateResult { ShakeIntensity = invalidIntensity };
|
||||
|
||||
// Assert
|
||||
act.Should().Throw<ArgumentOutOfRangeException>()
|
||||
.WithMessage("*must be between 0.0 and 1.0*");
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void EstimateResult_ShouldThrowForNullEstimateText()
|
||||
{
|
||||
// Act
|
||||
Action act = () => _ = new EstimateResult { EstimateText = null! };
|
||||
|
||||
// Assert
|
||||
act.Should().Throw<ArgumentNullException>()
|
||||
.WithParameterName("value");
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData("")]
|
||||
[InlineData(" ")]
|
||||
public void EstimateResult_ShouldThrowForEmptyOrWhitespaceEstimateText(string invalidText)
|
||||
{
|
||||
// Act
|
||||
Action act = () => _ = new EstimateResult { EstimateText = invalidText };
|
||||
|
||||
// Assert
|
||||
act.Should().Throw<ArgumentException>()
|
||||
.WithMessage("*cannot be empty or whitespace*");
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void EstimateResult_ShouldAcceptZeroDuration()
|
||||
{
|
||||
// Act
|
||||
var result = new EstimateResult { ShakeDuration = TimeSpan.Zero };
|
||||
|
||||
// Assert
|
||||
result.ShakeDuration.Should().Be(TimeSpan.Zero);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void EstimateResult_ShouldGenerateUniqueIds()
|
||||
{
|
||||
// Arrange & Act
|
||||
var result1 = EstimateResult.Create("test1", EstimateMode.Work, 0.5, TimeSpan.FromSeconds(1));
|
||||
var result2 = EstimateResult.Create("test2", EstimateMode.Work, 0.5, TimeSpan.FromSeconds(1));
|
||||
|
||||
// Assert
|
||||
result1.Id.Should().NotBe(result2.Id);
|
||||
result1.Id.Should().NotBeEmpty();
|
||||
result2.Id.Should().NotBeEmpty();
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void EstimateResult_Create_ShouldSetTimestampAutomatically()
|
||||
{
|
||||
// Arrange
|
||||
var before = DateTimeOffset.UtcNow;
|
||||
|
||||
// Act
|
||||
var result = EstimateResult.Create("test", EstimateMode.Work, 0.5, TimeSpan.FromSeconds(1));
|
||||
var after = DateTimeOffset.UtcNow;
|
||||
|
||||
// Assert
|
||||
result.Timestamp.Should().BeOnOrAfter(before);
|
||||
result.Timestamp.Should().BeOnOrBefore(after);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void EstimateResult_Create_ShouldSetAllProperties()
|
||||
{
|
||||
// Arrange
|
||||
var estimateText = "3 months";
|
||||
var mode = EstimateMode.Generic;
|
||||
var intensity = 0.8;
|
||||
var duration = TimeSpan.FromSeconds(10);
|
||||
|
||||
// Act
|
||||
var result = EstimateResult.Create(estimateText, mode, intensity, duration);
|
||||
|
||||
// Assert
|
||||
result.EstimateText.Should().Be(estimateText);
|
||||
result.Mode.Should().Be(mode);
|
||||
result.ShakeIntensity.Should().Be(intensity);
|
||||
result.ShakeDuration.Should().Be(duration);
|
||||
}
|
||||
}
|
||||
106
tests/HihaArvio.Tests/Models/ShakeDataTests.cs
Normal file
106
tests/HihaArvio.Tests/Models/ShakeDataTests.cs
Normal file
@@ -0,0 +1,106 @@
|
||||
using FluentAssertions;
|
||||
using HihaArvio.Models;
|
||||
|
||||
namespace HihaArvio.Tests.Models;
|
||||
|
||||
public class ShakeDataTests
|
||||
{
|
||||
[Fact]
|
||||
public void ShakeData_ShouldCreateWithAllProperties()
|
||||
{
|
||||
// Arrange
|
||||
var intensity = 0.65;
|
||||
var duration = TimeSpan.FromSeconds(3);
|
||||
var isShaking = true;
|
||||
|
||||
// Act
|
||||
var shakeData = new ShakeData
|
||||
{
|
||||
Intensity = intensity,
|
||||
Duration = duration,
|
||||
IsShaking = isShaking
|
||||
};
|
||||
|
||||
// Assert
|
||||
shakeData.Intensity.Should().Be(intensity);
|
||||
shakeData.Duration.Should().Be(duration);
|
||||
shakeData.IsShaking.Should().Be(isShaking);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(0.0)]
|
||||
[InlineData(0.25)]
|
||||
[InlineData(0.5)]
|
||||
[InlineData(0.75)]
|
||||
[InlineData(1.0)]
|
||||
public void ShakeData_ShouldAcceptValidIntensityValues(double intensity)
|
||||
{
|
||||
// Act
|
||||
var shakeData = new ShakeData { Intensity = intensity };
|
||||
|
||||
// Assert
|
||||
shakeData.Intensity.Should().Be(intensity);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(-0.1)]
|
||||
[InlineData(-1.0)]
|
||||
[InlineData(1.01)]
|
||||
[InlineData(2.0)]
|
||||
public void ShakeData_ShouldThrowForInvalidIntensity(double invalidIntensity)
|
||||
{
|
||||
// Act
|
||||
Action act = () => _ = new ShakeData { Intensity = invalidIntensity };
|
||||
|
||||
// Assert
|
||||
act.Should().Throw<ArgumentOutOfRangeException>()
|
||||
.WithMessage("*must be between 0.0 and 1.0*");
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void ShakeData_ShouldAcceptZeroDuration()
|
||||
{
|
||||
// Act
|
||||
var shakeData = new ShakeData { Duration = TimeSpan.Zero };
|
||||
|
||||
// Assert
|
||||
shakeData.Duration.Should().Be(TimeSpan.Zero);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void ShakeData_ShouldAcceptPositiveDuration()
|
||||
{
|
||||
// Arrange
|
||||
var duration = TimeSpan.FromSeconds(15.5);
|
||||
|
||||
// Act
|
||||
var shakeData = new ShakeData { Duration = duration };
|
||||
|
||||
// Assert
|
||||
shakeData.Duration.Should().Be(duration);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(true)]
|
||||
[InlineData(false)]
|
||||
public void ShakeData_ShouldAcceptBooleanIsShakingValues(bool isShaking)
|
||||
{
|
||||
// Act
|
||||
var shakeData = new ShakeData { IsShaking = isShaking };
|
||||
|
||||
// Assert
|
||||
shakeData.IsShaking.Should().Be(isShaking);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void ShakeData_DefaultConstructor_ShouldSetDefaultValues()
|
||||
{
|
||||
// Act
|
||||
var shakeData = new ShakeData();
|
||||
|
||||
// Assert
|
||||
shakeData.Intensity.Should().Be(0.0);
|
||||
shakeData.Duration.Should().Be(TimeSpan.Zero);
|
||||
shakeData.IsShaking.Should().BeFalse();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,490 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<coverage line-rate="0.5128" branch-rate="0.875" version="1.9" timestamp="1763460415" lines-covered="60" lines-valid="117" branches-covered="14" branches-valid="16">
|
||||
<sources>
|
||||
<source>/Users/ivuorinen/Code/ivuorinen/hiha-arvio/src/HihaArvio/</source>
|
||||
</sources>
|
||||
<packages>
|
||||
<package name="HihaArvio" line-rate="0.5128" branch-rate="0.875" complexity="41">
|
||||
<classes>
|
||||
<class name="__XamlGeneratedCode__.__Type416C8673F66D9458" filename="obj/Debug/net8.0/Microsoft.Maui.Controls.SourceGen/Microsoft.Maui.Controls.SourceGen.CodeBehindGenerator/Resources_Styles_Colors.xaml.sg.cs" line-rate="0" branch-rate="1" complexity="2">
|
||||
<methods>
|
||||
<method name="InitializeComponent" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="29" hits="0" branch="False" />
|
||||
<line number="30" hits="0" branch="False" />
|
||||
<line number="31" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name=".ctor" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="20" hits="0" branch="False" />
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="29" hits="0" branch="False" />
|
||||
<line number="30" hits="0" branch="False" />
|
||||
<line number="31" hits="0" branch="False" />
|
||||
<line number="20" hits="0" branch="False" />
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="__XamlGeneratedCode__.__Type76D52C8BE0F320C6" filename="obj/Debug/net8.0/Microsoft.Maui.Controls.SourceGen/Microsoft.Maui.Controls.SourceGen.CodeBehindGenerator/Resources_Styles_Styles.xaml.sg.cs" line-rate="0" branch-rate="1" complexity="2">
|
||||
<methods>
|
||||
<method name="InitializeComponent" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="29" hits="0" branch="False" />
|
||||
<line number="30" hits="0" branch="False" />
|
||||
<line number="31" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name=".ctor" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="20" hits="0" branch="False" />
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="29" hits="0" branch="False" />
|
||||
<line number="30" hits="0" branch="False" />
|
||||
<line number="31" hits="0" branch="False" />
|
||||
<line number="20" hits="0" branch="False" />
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.App" filename="obj/Debug/net8.0/Microsoft.Maui.Controls.SourceGen/Microsoft.Maui.Controls.SourceGen.CodeBehindGenerator/App.xaml.sg.cs" line-rate="0" branch-rate="1" complexity="1">
|
||||
<methods>
|
||||
<method name="InitializeComponent" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.App" filename="App.xaml.cs" line-rate="0" branch-rate="1" complexity="1">
|
||||
<methods>
|
||||
<method name=".ctor" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="5" hits="0" branch="False" />
|
||||
<line number="6" hits="0" branch="False" />
|
||||
<line number="7" hits="0" branch="False" />
|
||||
<line number="9" hits="0" branch="False" />
|
||||
<line number="10" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="5" hits="0" branch="False" />
|
||||
<line number="6" hits="0" branch="False" />
|
||||
<line number="7" hits="0" branch="False" />
|
||||
<line number="9" hits="0" branch="False" />
|
||||
<line number="10" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.AppShell" filename="obj/Debug/net8.0/Microsoft.Maui.Controls.SourceGen/Microsoft.Maui.Controls.SourceGen.CodeBehindGenerator/AppShell.xaml.sg.cs" line-rate="0" branch-rate="1" complexity="1">
|
||||
<methods>
|
||||
<method name="InitializeComponent" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.AppShell" filename="AppShell.xaml.cs" line-rate="0" branch-rate="1" complexity="1">
|
||||
<methods>
|
||||
<method name=".ctor" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="5" hits="0" branch="False" />
|
||||
<line number="6" hits="0" branch="False" />
|
||||
<line number="7" hits="0" branch="False" />
|
||||
<line number="8" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="5" hits="0" branch="False" />
|
||||
<line number="6" hits="0" branch="False" />
|
||||
<line number="7" hits="0" branch="False" />
|
||||
<line number="8" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.MainPage" filename="MainPage.xaml.cs" line-rate="0" branch-rate="0" complexity="3">
|
||||
<methods>
|
||||
<method name="OnCounterClicked" signature="(System.Object,System.EventArgs)" line-rate="0" branch-rate="0" complexity="2">
|
||||
<lines>
|
||||
<line number="13" hits="0" branch="False" />
|
||||
<line number="14" hits="0" branch="False" />
|
||||
<line number="16" hits="0" branch="True" condition-coverage="0% (0/2)">
|
||||
<conditions>
|
||||
<condition number="26" type="jump" coverage="0%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="17" hits="0" branch="False" />
|
||||
<line number="19" hits="0" branch="False" />
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name=".ctor" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="5" hits="0" branch="False" />
|
||||
<line number="7" hits="0" branch="False" />
|
||||
<line number="8" hits="0" branch="False" />
|
||||
<line number="9" hits="0" branch="False" />
|
||||
<line number="10" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="13" hits="0" branch="False" />
|
||||
<line number="14" hits="0" branch="False" />
|
||||
<line number="16" hits="0" branch="True" condition-coverage="0% (0/2)">
|
||||
<conditions>
|
||||
<condition number="26" type="jump" coverage="0%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="17" hits="0" branch="False" />
|
||||
<line number="19" hits="0" branch="False" />
|
||||
<line number="21" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="5" hits="0" branch="False" />
|
||||
<line number="7" hits="0" branch="False" />
|
||||
<line number="8" hits="0" branch="False" />
|
||||
<line number="9" hits="0" branch="False" />
|
||||
<line number="10" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.MainPage" filename="obj/Debug/net8.0/Microsoft.Maui.Controls.SourceGen/Microsoft.Maui.Controls.SourceGen.CodeBehindGenerator/MainPage.xaml.sg.cs" line-rate="0" branch-rate="1" complexity="1">
|
||||
<methods>
|
||||
<method name="InitializeComponent" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="25" hits="0" branch="False" />
|
||||
<line number="26" hits="0" branch="False" />
|
||||
<line number="27" hits="0" branch="False" />
|
||||
<line number="28" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="25" hits="0" branch="False" />
|
||||
<line number="26" hits="0" branch="False" />
|
||||
<line number="27" hits="0" branch="False" />
|
||||
<line number="28" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.MauiProgram" filename="MauiProgram.cs" line-rate="0" branch-rate="1" complexity="1">
|
||||
<methods>
|
||||
<method name="CreateMauiApp" signature="()" line-rate="0" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="8" hits="0" branch="False" />
|
||||
<line number="9" hits="0" branch="False" />
|
||||
<line number="10" hits="0" branch="False" />
|
||||
<line number="11" hits="0" branch="False" />
|
||||
<line number="12" hits="0" branch="False" />
|
||||
<line number="13" hits="0" branch="False" />
|
||||
<line number="14" hits="0" branch="False" />
|
||||
<line number="15" hits="0" branch="False" />
|
||||
<line number="16" hits="0" branch="False" />
|
||||
<line number="19" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="8" hits="0" branch="False" />
|
||||
<line number="9" hits="0" branch="False" />
|
||||
<line number="10" hits="0" branch="False" />
|
||||
<line number="11" hits="0" branch="False" />
|
||||
<line number="12" hits="0" branch="False" />
|
||||
<line number="13" hits="0" branch="False" />
|
||||
<line number="14" hits="0" branch="False" />
|
||||
<line number="15" hits="0" branch="False" />
|
||||
<line number="16" hits="0" branch="False" />
|
||||
<line number="19" hits="0" branch="False" />
|
||||
<line number="22" hits="0" branch="False" />
|
||||
<line number="23" hits="0" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.Models.AppSettings" filename="Models/AppSettings.cs" line-rate="1" branch-rate="1" complexity="5">
|
||||
<methods>
|
||||
<method name="get_SelectedMode" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="14" hits="22" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="get_MaxHistorySize" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="23" hits="7" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="set_MaxHistorySize" signature="(System.Int32)" line-rate="1" branch-rate="1" complexity="2">
|
||||
<lines>
|
||||
<line number="25" hits="8" branch="False" />
|
||||
<line number="26" hits="8" branch="True" condition-coverage="100% (2/2)">
|
||||
<conditions>
|
||||
<condition number="10" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="27" hits="3" branch="False" />
|
||||
<line number="28" hits="3" branch="False" />
|
||||
<line number="29" hits="3" branch="False" />
|
||||
<line number="30" hits="3" branch="False" />
|
||||
<line number="31" hits="3" branch="False" />
|
||||
<line number="34" hits="5" branch="False" />
|
||||
<line number="35" hits="5" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name=".ctor" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="8" hits="14" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="14" hits="22" branch="False" />
|
||||
<line number="23" hits="7" branch="False" />
|
||||
<line number="25" hits="8" branch="False" />
|
||||
<line number="26" hits="8" branch="True" condition-coverage="100% (2/2)">
|
||||
<conditions>
|
||||
<condition number="10" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="27" hits="3" branch="False" />
|
||||
<line number="28" hits="3" branch="False" />
|
||||
<line number="29" hits="3" branch="False" />
|
||||
<line number="30" hits="3" branch="False" />
|
||||
<line number="31" hits="3" branch="False" />
|
||||
<line number="34" hits="5" branch="False" />
|
||||
<line number="35" hits="5" branch="False" />
|
||||
<line number="8" hits="14" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.Models.EstimateResult" filename="Models/EstimateResult.cs" line-rate="1" branch-rate="1" complexity="16">
|
||||
<methods>
|
||||
<method name="get_Id" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="14" hits="10" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="get_Timestamp" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="19" hits="8" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="get_EstimateText" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="28" hits="2" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="set_EstimateText" signature="(System.String)" line-rate="1" branch-rate="1" complexity="4">
|
||||
<lines>
|
||||
<line number="30" hits="8" branch="False" />
|
||||
<line number="31" hits="8" branch="True" condition-coverage="100% (2/2)">
|
||||
<conditions>
|
||||
<condition number="7" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="32" hits="1" branch="False" />
|
||||
<line number="33" hits="1" branch="False" />
|
||||
<line number="36" hits="7" branch="True" condition-coverage="100% (2/2)">
|
||||
<conditions>
|
||||
<condition number="34" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="37" hits="2" branch="False" />
|
||||
<line number="38" hits="2" branch="False" />
|
||||
<line number="41" hits="5" branch="False" />
|
||||
<line number="42" hits="5" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="get_Mode" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="48" hits="7" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="get_ShakeIntensity" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="56" hits="6" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="set_ShakeIntensity" signature="(System.Double)" line-rate="1" branch-rate="1" complexity="4">
|
||||
<lines>
|
||||
<line number="58" hits="12" branch="False" />
|
||||
<line number="59" hits="12" branch="True" condition-coverage="100% (4/4)">
|
||||
<conditions>
|
||||
<condition number="11" type="jump" coverage="100%" />
|
||||
<condition number="30" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="60" hits="3" branch="False" />
|
||||
<line number="61" hits="3" branch="False" />
|
||||
<line number="62" hits="3" branch="False" />
|
||||
<line number="63" hits="3" branch="False" />
|
||||
<line number="64" hits="3" branch="False" />
|
||||
<line number="67" hits="9" branch="False" />
|
||||
<line number="68" hits="9" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="get_ShakeDuration" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="74" hits="9" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="Create" signature="(System.String,HihaArvio.Models.EstimateMode,System.Double,System.TimeSpan)" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="89" hits="4" branch="False" />
|
||||
<line number="90" hits="4" branch="False" />
|
||||
<line number="91" hits="4" branch="False" />
|
||||
<line number="92" hits="4" branch="False" />
|
||||
<line number="93" hits="4" branch="False" />
|
||||
<line number="94" hits="4" branch="False" />
|
||||
<line number="95" hits="4" branch="False" />
|
||||
<line number="96" hits="4" branch="False" />
|
||||
<line number="97" hits="4" branch="False" />
|
||||
<line number="98" hits="4" branch="False" />
|
||||
<line number="99" hits="4" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name=".ctor" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="8" hits="16" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="14" hits="10" branch="False" />
|
||||
<line number="19" hits="8" branch="False" />
|
||||
<line number="28" hits="2" branch="False" />
|
||||
<line number="30" hits="8" branch="False" />
|
||||
<line number="31" hits="8" branch="True" condition-coverage="100% (2/2)">
|
||||
<conditions>
|
||||
<condition number="7" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="32" hits="1" branch="False" />
|
||||
<line number="33" hits="1" branch="False" />
|
||||
<line number="36" hits="7" branch="True" condition-coverage="100% (2/2)">
|
||||
<conditions>
|
||||
<condition number="34" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="37" hits="2" branch="False" />
|
||||
<line number="38" hits="2" branch="False" />
|
||||
<line number="41" hits="5" branch="False" />
|
||||
<line number="42" hits="5" branch="False" />
|
||||
<line number="48" hits="7" branch="False" />
|
||||
<line number="56" hits="6" branch="False" />
|
||||
<line number="58" hits="12" branch="False" />
|
||||
<line number="59" hits="12" branch="True" condition-coverage="100% (4/4)">
|
||||
<conditions>
|
||||
<condition number="11" type="jump" coverage="100%" />
|
||||
<condition number="30" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="60" hits="3" branch="False" />
|
||||
<line number="61" hits="3" branch="False" />
|
||||
<line number="62" hits="3" branch="False" />
|
||||
<line number="63" hits="3" branch="False" />
|
||||
<line number="64" hits="3" branch="False" />
|
||||
<line number="67" hits="9" branch="False" />
|
||||
<line number="68" hits="9" branch="False" />
|
||||
<line number="74" hits="9" branch="False" />
|
||||
<line number="89" hits="4" branch="False" />
|
||||
<line number="90" hits="4" branch="False" />
|
||||
<line number="91" hits="4" branch="False" />
|
||||
<line number="92" hits="4" branch="False" />
|
||||
<line number="93" hits="4" branch="False" />
|
||||
<line number="94" hits="4" branch="False" />
|
||||
<line number="95" hits="4" branch="False" />
|
||||
<line number="96" hits="4" branch="False" />
|
||||
<line number="97" hits="4" branch="False" />
|
||||
<line number="98" hits="4" branch="False" />
|
||||
<line number="99" hits="4" branch="False" />
|
||||
<line number="8" hits="16" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
<class name="HihaArvio.Models.ShakeData" filename="Models/ShakeData.cs" line-rate="1" branch-rate="1" complexity="7">
|
||||
<methods>
|
||||
<method name="get_Intensity" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="16" hits="7" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="set_Intensity" signature="(System.Double)" line-rate="1" branch-rate="1" complexity="4">
|
||||
<lines>
|
||||
<line number="18" hits="10" branch="False" />
|
||||
<line number="19" hits="10" branch="True" condition-coverage="100% (4/4)">
|
||||
<conditions>
|
||||
<condition number="11" type="jump" coverage="100%" />
|
||||
<condition number="30" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="20" hits="4" branch="False" />
|
||||
<line number="21" hits="4" branch="False" />
|
||||
<line number="22" hits="4" branch="False" />
|
||||
<line number="23" hits="4" branch="False" />
|
||||
<line number="24" hits="4" branch="False" />
|
||||
<line number="27" hits="6" branch="False" />
|
||||
<line number="28" hits="6" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="get_Duration" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="34" hits="7" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
<method name="get_IsShaking" signature="()" line-rate="1" branch-rate="1" complexity="1">
|
||||
<lines>
|
||||
<line number="39" hits="7" branch="False" />
|
||||
</lines>
|
||||
</method>
|
||||
</methods>
|
||||
<lines>
|
||||
<line number="16" hits="7" branch="False" />
|
||||
<line number="18" hits="10" branch="False" />
|
||||
<line number="19" hits="10" branch="True" condition-coverage="100% (4/4)">
|
||||
<conditions>
|
||||
<condition number="11" type="jump" coverage="100%" />
|
||||
<condition number="30" type="jump" coverage="100%" />
|
||||
</conditions>
|
||||
</line>
|
||||
<line number="20" hits="4" branch="False" />
|
||||
<line number="21" hits="4" branch="False" />
|
||||
<line number="22" hits="4" branch="False" />
|
||||
<line number="23" hits="4" branch="False" />
|
||||
<line number="24" hits="4" branch="False" />
|
||||
<line number="27" hits="6" branch="False" />
|
||||
<line number="28" hits="6" branch="False" />
|
||||
<line number="34" hits="7" branch="False" />
|
||||
<line number="39" hits="7" branch="False" />
|
||||
</lines>
|
||||
</class>
|
||||
</classes>
|
||||
</package>
|
||||
</packages>
|
||||
</coverage>
|
||||
Reference in New Issue
Block a user