color: the palette tests define the swatch exchange constants craft-cms keeps private

This commit is contained in:
bflatastic
2026-11-19 07:18:08 +07:00
parent 693785fc70
commit 4e63316d9a
+7
View File
@@ -2,6 +2,13 @@ use super::*;
use crate::{Gradient, GradientPaint, GradientStop};
use proptest::prelude::*;
// The swatch exchange file's signature, block types and entry cap, which craft-cms keeps private.
const ASE_SIGNATURE: &[u8] = b"ASEF";
const ASE_GROUP_START: u16 = 0xC001;
const ASE_GROUP_END: u16 = 0xC002;
const ASE_COLOR: u16 = 0x0001;
const ASE_MAX_ENTRIES: usize = 100_000;
#[test]
fn gpl_blank_name_keeps_fallback() {
let blank = "GIMP Palette\nName: \nColumns: 0\n#\n 1 2 3\tx\n";