GeoTownFactory   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 13
c 1
b 0
f 0
dl 0
loc 17
ccs 0
cts 10
cp 0
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A definition() 0 13 1
1
<?php
2
3
namespace UKTowns\Models;
4
5
use Illuminate\Database\Eloquent\Factories\Factory;
6
7
class GeoTownFactory extends Factory
8
{
9
    protected $model = GeoTown::class;
10
11
    public function definition()
12
    {
13
        return [
14
            'place_name'     => $this->faker->city(),
15
            'county'         => $this->faker->city(),
16
            'country'        => $this->faker->city(),
17
            'grid_reference' => $this->faker->word(),
18
            'easting'        => random_int(0, 999),
19
            'northing'       => random_int(0, 999),
20
            'latitude'       => $this->faker->latitude(),
21
            'longitude'      => $this->faker->longitude(),
22
            'postcode_area'  => $this->faker->postcode(),
23
            'type'           => 'Other',
24
        ];
25
    }
26
}
27