Stufe 4c (#764): Kommentare in C#, WebUI-Skripten, CSS und HTML auf Englisch
Rund 2.600 Kommentarblöcke in 310 C#-Dateien übersetzt, Begründungen vollständig erhalten: blockweise gleiche Anzahl wie vorher, kein Block unter 60 % seiner Länge, der Code außerhalb der Kommentare per Tokenizer byte-identisch geprüft. Zitate deutscher Oberflächentexte und Testdaten bleiben deutsch. WebUI: Kommentare in JS/CSS/HTML übersetzt, JSDoc-@param an die in 4b umbenannten Parameter angeglichen. Dabei behoben: - 4b hatte "tag" (HTML-Tag) als deutsches "Tag" gelesen und zu "dayValue" gemacht (makeElement, svg, Tagesübersicht) - zurück auf tag/day. - Aufgaben "InProgress" bekamen die Plakettenart "laufend", für die es nie eine CSS-Klasse gab - jetzt "success" wie laufende Instanzen. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
da4ceac7d5
commit
837a634a22
@@ -4,8 +4,8 @@ using Shouldly;
|
||||
namespace ClawdDotNet.Manager.Tests;
|
||||
|
||||
/// <summary>
|
||||
/// <c>manager.json</c> und der Protokollauszug — die beiden Stellen, an denen der Manager
|
||||
/// mit dem Dateisystem spricht (#528, Stufe 3).
|
||||
/// <c>manager.json</c> and the log excerpt — the two places where the manager
|
||||
/// talks to the file system (#528, stage 3).
|
||||
/// </summary>
|
||||
public sealed class ManagerSettingsTests : IDisposable
|
||||
{
|
||||
@@ -17,7 +17,7 @@ public sealed class ManagerSettingsTests : IDisposable
|
||||
public void Dispose()
|
||||
{
|
||||
try { Directory.Delete(_dir, recursive: true); }
|
||||
catch { /* Ein liegengebliebener Testordner faerbt keinen Lauf rot. */ }
|
||||
catch { /* A leftover test folder does not turn a run red. */ }
|
||||
}
|
||||
|
||||
[Fact]
|
||||
@@ -32,8 +32,8 @@ public sealed class ManagerSettingsTests : IDisposable
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Master-Token und Lizenzschlüssel liegen in der Datei nicht im Klartext — zur
|
||||
/// Laufzeit aber schon, sonst könnte niemand damit arbeiten.
|
||||
/// Master token and license key are not in plain text in the file — but they are at
|
||||
/// runtime, otherwise nobody could work with them.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public void Geheimnisse_stehen_nicht_im_Klartext_in_der_Datei()
|
||||
@@ -54,19 +54,19 @@ public sealed class ManagerSettingsTests : IDisposable
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Eine von Hand oder von PowerShell geschriebene Datei hat oft ein Byte-Order-Mark,
|
||||
/// und sie darf trotzdem gelten.
|
||||
/// A file written by hand or by PowerShell often has a byte order mark,
|
||||
/// and it must still apply.
|
||||
///
|
||||
/// <para>Beim Abnahmelauf sah es aus, als würde sie ignoriert — der Manager arbeitete
|
||||
/// mit Vorgaben. Dieser Test klärt, ob das an der Datei lag.</para>
|
||||
/// <para>In the acceptance run it looked as if it were ignored — the manager worked
|
||||
/// with defaults. This test clarifies whether that was due to the file.</para>
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public void Eine_Datei_mit_Byte_Order_Mark_gilt_auch()
|
||||
{
|
||||
var pfad = Path.Combine(_dir, "manager.json");
|
||||
|
||||
// Genau so, wie PowerShell es schreibt: mit BOM, mit doppelten Leerzeichen nach
|
||||
// dem Doppelpunkt, und mit verdoppelten Backslashes im Pfad.
|
||||
// Exactly as PowerShell writes it: with BOM, with double spaces after
|
||||
// the colon, and with doubled backslashes in the path.
|
||||
var inhalt = """
|
||||
{
|
||||
"instanceExecutable": "J:\\Programme\\ClawdDotNet.exe",
|
||||
@@ -88,8 +88,8 @@ public sealed class ManagerSettingsTests : IDisposable
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Eine unlesbare Datei darf den Manager nicht am Start hindern — dann liefe gar
|
||||
/// keine Instanz mehr, und das ist der schlechtere Zustand.
|
||||
/// An unreadable file must not prevent the manager from starting — then
|
||||
/// no instance would run at all, and that is the worse state.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public void Eine_kaputte_Datei_verhindert_den_Start_nicht()
|
||||
@@ -100,15 +100,15 @@ public sealed class ManagerSettingsTests : IDisposable
|
||||
|
||||
store.Load().WebUiPort.ShouldBe(7000);
|
||||
|
||||
// Und der Grund steht fest - sonst arbeitet der Manager stillschweigend mit
|
||||
// Vorgaben, und niemand kann sagen, warum sein Instanzverzeichnis falsch ist.
|
||||
// And the reason is recorded - otherwise the manager silently works with
|
||||
// defaults, and nobody can say why its instance directory is wrong.
|
||||
store.LoadProblem.ShouldNotBeNullOrWhiteSpace();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Unsinnige Zahlen können in einer von Hand bearbeitbaren Datei stehen. Ein
|
||||
/// Abfragetakt von 0 wäre eine Endlosschleife, ein Alarm nach null Fehlversuchen ein
|
||||
/// Alarm bei jedem Aussetzer.
|
||||
/// Nonsensical numbers can be in a hand-editable file. A
|
||||
/// probe interval of 0 would be an endless loop, an alarm after zero failed attempts an
|
||||
/// alarm at every hiccup.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public void Unsinnige_Aufsichtswerte_werden_eingefangen()
|
||||
@@ -130,7 +130,7 @@ public sealed class ManagerSettingsTests : IDisposable
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Der Protokollauszug, der einer Absturzmeldung erst ihren Wert gibt.</summary>
|
||||
/// <summary>The log excerpt that only gives a crash report its value.</summary>
|
||||
public sealed class InstanceLogExcerptTests : IDisposable
|
||||
{
|
||||
private readonly string _instanz = Path.Combine(
|
||||
@@ -141,7 +141,7 @@ public sealed class InstanceLogExcerptTests : IDisposable
|
||||
public void Dispose()
|
||||
{
|
||||
try { Directory.Delete(_instanz, recursive: true); }
|
||||
catch { /* Ein liegengebliebener Testordner faerbt keinen Lauf rot. */ }
|
||||
catch { /* A leftover test folder does not turn a run red. */ }
|
||||
}
|
||||
|
||||
private void Schreibe(string tag, string modul, params string[] zeilen)
|
||||
@@ -154,15 +154,15 @@ public sealed class InstanceLogExcerptTests : IDisposable
|
||||
[Fact]
|
||||
public void Ohne_Protokoll_kommt_nichts_zurueck()
|
||||
{
|
||||
// Kein Fehler, sondern ein Befund: Ein Prozess, der erschlagen wurde, bevor sein
|
||||
// Schreibpuffer geleert war, hinterlaesst genau nichts (#529).
|
||||
// Not an error, but a finding: a process that was killed before its
|
||||
// write buffer was flushed leaves exactly nothing (#529).
|
||||
InstanceLogExcerpt.Read(_instanz).ShouldBeEmpty();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Module beschreiben denselben Zeitraum. Bei einem Absturz will man wissen, was
|
||||
/// gleichzeitig passiert ist — nicht erst alles aus einer Datei, dann alles aus der
|
||||
/// nächsten.
|
||||
/// Modules describe the same period. With a crash you want to know what
|
||||
/// happened at the same time — not first everything from one file, then everything from the
|
||||
/// next.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public void Die_Module_werden_nach_Zeit_zusammengefuehrt()
|
||||
@@ -181,7 +181,7 @@ public sealed class InstanceLogExcerptTests : IDisposable
|
||||
zeilen[1].ShouldContain("17:26:49");
|
||||
zeilen[2].ShouldContain("17:26:50");
|
||||
|
||||
// Aus welcher Datei eine Zeile stammt, gehoert dazu.
|
||||
// Which file a line comes from is part of it.
|
||||
zeilen[1].ShouldStartWith("Web.log:");
|
||||
}
|
||||
|
||||
@@ -204,8 +204,8 @@ public sealed class InstanceLogExcerptTests : IDisposable
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Die Datei kann in genau diesem Moment noch beschrieben werden — von einer Instanz,
|
||||
/// die gerade endet. Wer sie exklusiv öffnen wollte, bekäme im Zweifel gar nichts.
|
||||
/// The file may still be written to at exactly this moment — by an instance
|
||||
/// that is just ending. Whoever wanted to open it exclusively might get nothing at all.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public void Eine_offen_beschriebene_Datei_laesst_sich_lesen()
|
||||
|
||||
Reference in New Issue
Block a user