Git Komut Rehberi & Terminal Asistanı
Sıfırdan Yeni Bir Depo Başlatın:
Mevcut Bir Git Deposu veya Klasörü Gönderin:
Hataları Geri Alma, İptal & Temizlik:
Son commit'i geri al (yapılan değişiklikleri korur):
git reset --soft HEAD~1
Yapılan yerel değişiklikleri iptal et (çalışma ağacını temizler):
git restore .
Takip edilmeyen gereksiz dosyaları sil:
git clean -fd
Değişiklikleri geçici sakla ve geri getir (stash):
git stash git stash pop
Dal (Branch) ve Sürüm Etiketleri:
Yeni dal aç ve geçiş yap:
git checkout -b yeni-ozellik git push -u origin yeni-ozellik
Sürüm etiketi (tag) oluştur ve gönder:
git tag -a v1.0.0 -m "Sürüm 1.0.0" git push origin --tags
feat: SnapCAD Studio'yu YakHub deposuna taşı
- DWG/DXF içe aktarma ve .skf yeniden açma düzeltmeleri - YakNet Bulut eşitlemede boş/eski kopya koruması ve yerel-only proje bildirimi - Panelden içe aktarma duyuruları ve erişilebilir Türkçe hata mesajları - AGPL-3.0 lisansı, README ve YakHub bağlantıları
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { exportMeshesToObj, type ObjExportMesh } from "@/lib/objExport";
|
||||
import { exportMeshesToObj, generateMtlContent, type ObjExportMesh } from "@/lib/objExport";
|
||||
|
||||
function duplicatedTetrahedron(): ObjExportMesh {
|
||||
const a: [number, number, number] = [0, 0, 0];
|
||||
@@ -40,4 +40,16 @@ describe("OBJ export", () => {
|
||||
expect(faces).toHaveLength(4);
|
||||
expect([...edgeUse.values()].every((count) => count === 2)).toBe(true);
|
||||
});
|
||||
|
||||
it("generates companion .mtl material library and references it in .obj", () => {
|
||||
const mesh = duplicatedTetrahedron();
|
||||
const colors = { closed_tetrahedron: "#ff5500" };
|
||||
const mtl = generateMtlContent([mesh], colors);
|
||||
const obj = exportMeshesToObj([mesh], { mtlFileName: "model.mtl", colors });
|
||||
|
||||
expect(mtl).toContain("newmtl Material_closed_tetrahedron");
|
||||
expect(mtl).toContain("Kd 1 0.3333 0");
|
||||
expect(obj).toContain("mtllib model.mtl");
|
||||
expect(obj).toContain("usemtl Material_closed_tetrahedron");
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user