diff --git a/tests/unit/DepreciationTest.php b/tests/unit/DepreciationTest.php
index bb31de772cb9def5d69b7cdf61432a53e7717da4..b883b891b1e70f4545100cc0ba1dd4986236502c 100644
--- a/tests/unit/DepreciationTest.php
+++ b/tests/unit/DepreciationTest.php
@@ -39,11 +39,11 @@ class DepreciationTest extends BaseTest
      {
          $category = $this->createValidCategory('license-graphics-category');
          $depreciation = $this->createValidDepreciation('computer', ['name' => 'New Depreciation']);
-         $licenses = factory(App\Models\License::class, 5)->states('photoshop')->create([
+         $licenses = factory(App\Models\LicenseModel::class, 5)->states('photoshop')->create([
              'depreciation_id'=>$depreciation->id,
              'category_id' => $category->id
          ]);
 
-         $this->assertEquals(5,$depreciation->has_licenses());
+         $this->assertEquals(5,$depreciation->licenses()->count());
      }
 }