### ----------------------------------------------------
### -- StrictClass
### -- Licenses: Artistic-2.0
### -- Authors: Martin Barth
### -- File: t/03-required.t
### ----------------------------------------------------
use v6.c;
use Test;
use StrictClass;

class Foo does StrictClass {
    has $.a is required;
    has %.b;
}

lives-ok {
    Foo.new(a => 1, b => {bb => 2, bbb => 3});
}, 'Can create an instace of a Class that does StrictClass';

dies-ok {
    Foo.new(a => 1, b => 2, c => 3);
}, 'Can not create an instance of a class that does StrictClass with to many parameters';

done-testing;


