File Coverage

lib/UR/Namespace/Command/Define/Datasource/File.pm
Criterion Covered Total %
statement 12 16 75.0
branch n/a
condition n/a
subroutine 4 6 66.6
pod 0 1 0.0
total 16 23 69.5


line stmt bran cond sub pod time code
1             package UR::Namespace::Command::Define::Datasource::File;
2              
3 1     1   32 use strict;
  1         2  
  1         41  
4 1     1   3 use warnings;
  1         1  
  1         24  
5 1     1   4 use UR;
  1         1  
  1         4  
6             our $VERSION = "0.46"; # UR $VERSION;
7              
8 1     1   4 use IO::File;
  1         1  
  1         199  
9              
10             UR::Object::Type->define(
11             class_name => __PACKAGE__,
12             is => 'UR::Namespace::Command::Define::Datasource',
13             has => [
14             server => {
15             is => 'String',
16             doc => '"server" attribute for this data source, such as a database name',
17             },
18             singleton => {
19             is => 'Boolean',
20             default_value => 1,
21             doc => 'by default all data sources are singletons, but this can be turned off'
22             },
23             ],
24             doc => 'Add a file-based data source (not yet implemented)'
25             );
26              
27             sub help_description {
28 0     0 0   "Define a UR datasource connected to a file";
29             }
30              
31             sub execute {
32 0     0     my $self = shift;
33              
34 0           $self->warning_message("This command is not yet implemented. See the documentation for UR::DataSource::File for more information about creating file-based data sources");
35 0           return;
36             }
37              
38             1;
39