Codebasis als Dateien ins Arbeitsrepo statt als Gitlink

QuellCode/CentronERP war nur als Gitlink (Submodul-Referenz auf 79c1142)
getrackt, ohne .gitmodules und ohne erreichbares Remote. Der
Untersuchungsgegenstand der Versuchsreihe war damit nicht reproduzierbar
gesichert: Ein Klon haette ein leeres Verzeichnis erhalten, und die Belege
der 3.287 Anforderungen waeren nicht ueberpruefbar gewesen.

Umstellung:
- Historie nach c:\DEV\CentronERP_git_snapshot_79c1142 ausgelagert
  (vollstaendig lesbar, enthaelt 79c1142 und Vorgaenger 89ccfd6)
- Gitlink aus dem Index entfernt
- Dateiinhalt aufgenommen: 24.557 Dateien, rund 333 MB

Die verschachtelte .gitignore der Codebasis gilt weiter, Build-Artefakte
bleiben ausgeschlossen. Details in Versuche/Versuch_01/_Codebasis-Nachweis.md
This commit is contained in:
Christoph Schwörer
2026-08-26 07:43:51 +02:00
parent 18edae75b6
commit f045b99a25
24664 changed files with 5846716 additions and 1 deletions
@@ -0,0 +1,85 @@
using Centron.BusinessLogic;
using Centron.BusinessLogic.EmployeeArea;
using Centron.BusinessLogic.Warehousing;
using Centron.BusinessLogic.WebServices.Warehousing;
using Centron.Data.Entities.Administration.Logins;
using Centron.Data.WebServices.Warehousing;
using Centron.Tests.EndToEnd.Infrastructure;
using Xunit.Abstractions;
namespace Centron.Tests.EndToEnd.TicketTests.Ticket126856;
public class TicketTest126856Test : EndToEndTest
{
public TicketTest126856Test(ITestOutputHelper testOutputHelper) : base(testOutputHelper)
{
}
public override void Execute()
{
this.LoadAndSaveAnArticle();
}
private int ArticleI3D = 52;
private const int APPUSERI3D = 11;
private void LoadAndSaveAnArticle()
{
var user = WithSession(f => f.GetBL<AppUserBL>().GetAppUser(f => f.I3D == APPUSERI3D));
var article1 = WithSession(f => f.GetBL<ArticleWebServiceBL>().GetArticleByArticleI3D(ArticleI3D));
// change this property to ensure we run into the problematic code
article1.ScanBarcode = !article1.ScanBarcode;
// Should fail, because there is stock available for the article. In this case it is forbidden to change the ScanBarcode property
var result1 = WithSession(f => f.GetBL<ArticleWebServiceBL>().SaveArticle(article1, new LoggedInUser(user)));
this.Verifier.Verify("LoadAndSavedArticle_failed", result1);
// set all barcodes to 'booked out manually' so that the stock check is bypassed
base.Sql("UPDATE Barcode SET Status = 20 WHERE ArtikelI3D = 52 AND Status IN (1,2, 8)");
base.Sql("UPDATE ARTIK SET Menge = 0 WHERE I3D = 52");
//sometimes the changes tracker does not work right and bring the 'article has been changed by somebody else'-message, even if it's not the case
//so we save here to see, if this is happening now
result1 = WithSession(f => f.GetBL<ArticleWebServiceBL>().SaveArticle(article1, new LoggedInUser(user)));
this.Verifier.Verify("LoadAndSavedArticle", result1);
var article2 = WithSession(f => f.GetBL<ArticleWebServiceBL>().GetArticleByArticleI3D(ArticleI3D));
article2.ScanBarcode = !article2.ScanBarcode;
//sometime volume prices are not saved
article2.VolumePrices.Add(new ArticleVolumePricesDTO()
{
State = 0,
EK = (decimal)12.34,
FromAmount = 2,
VK1 = (decimal)56.78,
ArticleI3D = article2.I3D
});
article2.VolumePrices.Add(new ArticleVolumePricesDTO()
{
State = 1,
EK = (decimal)120.34,
FromAmount = 42,
VK1 = (decimal)560.78,
ArticleI3D = article2.I3D
});
var result2 = WithSession(f =>f.GetBL<ArticleWebServiceBL>().SaveArticle(article2, new LoggedInUser(user)));
this.Verifier.Verify("LoadAndSavedArticle_The_Second", result2);
var article3 = WithSession(f => f.GetBL<ArticleWebServiceBL>().GetArticleByArticleI3D(ArticleI3D));
article3.ScanBarcode = !article3.ScanBarcode;
//just check the first case again, because it does not always occur
var result3 = WithSession(f => f.GetBL<ArticleWebServiceBL>().SaveArticle(article3, new LoggedInUser(user)));
this.Verifier.Verify("LoadAndSavedArticle_Third_times_a_charm", result3);
// and because Easter is just around the corner, here is a bad pun
// What kind of jewelry does the easter bunny wear ?
// 24 carrot gold
}
}