Minor changes to configure methods

This commit is contained in:
Michael Miller 2021-04-26 17:17:18 -06:00
parent 6c98d7107c
commit f549fcfa7a
No known key found for this signature in database
GPG key ID: FB9F12F7C646A4AD
2 changed files with 2 additions and 2 deletions

View file

@ -50,7 +50,7 @@ module Spectator
# A `ConfigBuilder` is yielded to allow changing the configuration. # A `ConfigBuilder` is yielded to allow changing the configuration.
# NOTE: The configuration set here can be overriden # NOTE: The configuration set here can be overriden
# with a `.spectator` file and command-line arguments. # with a `.spectator` file and command-line arguments.
def configure : Nil def configure(& : ConfigBuilder -> _) : Nil
yield @@config_builder yield @@config_builder
end end

View file

@ -175,7 +175,7 @@ module Spectator
# Builds the configuration to use for the spec. # Builds the configuration to use for the spec.
# A `ConfigBuilder` is yielded to the block provided to this method. # A `ConfigBuilder` is yielded to the block provided to this method.
# That builder will be used to create the configuration. # That builder will be used to create the configuration.
def config def configure(& : ConfigBuilder -> _) : Nil
builder = ConfigBuilder.new builder = ConfigBuilder.new
yield builder yield builder
@config = builder.build @config = builder.build