Skip to content

Commit

Permalink
Add testcase for #298
Browse files Browse the repository at this point in the history
  • Loading branch information
dvdoug committed Feb 5, 2023
1 parent 7737cfc commit a390cf4
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions tests/PackerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -1118,6 +1118,28 @@ public function testIssue182B(): void
self::assertCount(62, $packer->getUnpackedItems());
}

public function testIssue298(): void
{
$this->markTestSkipped();
$packer = new Packer();
$packer->addBox(new TestBox('20 Feet', 6058, 2438, 2591, 2200, 5758, 2352, 2385, 24000));
$packer->addItem(new TestItem('Item 1', 1480, 1140, 1140, 1, Rotation::KeepFlat), 3);
$packer->addItem(new TestItem('Item 2', 1480, 1140, 750, 1, Rotation::KeepFlat), 19);
$packer->addItem(new TestItem('Item 3', 2240, 1480, 1200, 1, Rotation::KeepFlat), 1);
$packer->addItem(new TestItem('Item 4', 2240, 1480, 1300, 1, Rotation::KeepFlat), 1);
$packer->addItem(new TestItem('Item 5', 2240, 1480, 1480, 1, Rotation::KeepFlat), 1);
$packer->addItem(new TestItem('Item 6', 2240, 1480, 1600, 1, Rotation::KeepFlat), 6);
$packer->addItem(new TestItem('Item 7', 2240, 1480, 2240, 1, Rotation::KeepFlat), 8);
$packer->addItem(new TestItem('Item 8', 2240, 1480, 750, 1, Rotation::KeepFlat), 1);
$packer->addItem(new TestItem('Item 9', 250, 180, 150, 1, Rotation::KeepFlat), 1);
$packer->addItem(new TestItem('Item 10', 2600, 260, 1400, 1, Rotation::KeepFlat), 7);
$packer->addItem(new TestItem('Item 11', 400, 350, 230, 1, Rotation::KeepFlat), 2);

$packedBoxes = $packer->pack();

self::assertCount(6, $packedBoxes);
}

public function testIssue334(): void
{
$this->markTestSkipped();
Expand Down

0 comments on commit a390cf4

Please sign in to comment.