Class: CQL::Repository
- Inherits:
-
Object
- Object
- CQL::Repository
- Includes:
- Queriable
- Defined in:
- lib/cql/repository.rb
Overview
A repository is a group of models. See the corresponding Cucumber documentation for details.
Instance Attribute Summary
Attributes included from Queriable
Instance Method Summary collapse
-
#initialize(repository_root) ⇒ Repository
constructor
Creates a new repository object based on the passed directory path or model.
Methods included from Queriable
Constructor Details
#initialize(repository_root) ⇒ Repository
Creates a new repository object based on the passed directory path or model
11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/cql/repository.rb', line 11 def initialize(repository_root) case when repository_root.is_a?(String) root = CukeModeler::Directory.new(repository_root) when repository_root.class.to_s =~ /CukeModeler/ root = repository_root else raise(ArgumentError, "Don't know how to make a repository from a #{repository_root.class}") end @query_root = root end |