Add some test data for long url bug
This commit is contained in:
parent
e3ee803384
commit
09d0f9b71b
2 changed files with 18 additions and 2 deletions
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Database\Seeder;
|
||||
use Illuminate\Support\Carbon;
|
||||
|
||||
class ClientsTableSeeder extends Seeder
|
||||
{
|
||||
|
@ -17,5 +18,12 @@ class ClientsTableSeeder extends Seeder
|
|||
'created_at' => '2016-01-12 16:03:00',
|
||||
'updated_at' => '2016-01-12 16:03:00',
|
||||
]);
|
||||
|
||||
DB::table('clients')->insert([
|
||||
'client_url' => 'https://beta.indigenous.abode.pub/ios/',
|
||||
'client_name' => 'https://beta.indigenous.abode.pub/ios/',
|
||||
'created_at' => Carbon::now()->toDateTimeString(),
|
||||
'updated_at' => Carbon::now()->toDateTimeString(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,8 +14,6 @@ class NotesTableSeeder extends Seeder
|
|||
*/
|
||||
public function run()
|
||||
{
|
||||
//factory(Note::class, 10)->create();
|
||||
|
||||
$now = Carbon::now()->subDays(rand(2, 5));
|
||||
$noteTwitterReply = Note::create([
|
||||
'note' => 'What does this even mean?',
|
||||
|
@ -197,5 +195,15 @@ EOF;
|
|||
DB::table('notes')
|
||||
->where('id', $noteWithCode->id)
|
||||
->update(['updated_at' => $now->toDateTimeString()]);
|
||||
|
||||
$now = Carbon::now();
|
||||
$noteWithLongUrl = Note::create([
|
||||
'note' => 'Best site: https://example.org/posts/some-really-long-slug-that-is-too-wide-on-mobile',
|
||||
'created_at' => $now,
|
||||
'client_id' => 'https://beta.indigenous.abode.pub/ios/'
|
||||
]);
|
||||
DB::table('notes')
|
||||
->where('id', $noteWithLongUrl->id)
|
||||
->update(['updated_at' => $now->toDateTimeString()]);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue