File: 800_regressions_010_too_few_features.t

package info (click to toggle)
libtest-bdd-cucumber-perl 0.26-1~bpo70%2B1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy-backports
  • size: 528 kB
  • sloc: perl: 3,436; makefile: 8
file content (28 lines) | stat: -rw-r--r-- 585 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!perl

use strict;
use warnings;

use Test::More;
use Test::BDD::Cucumber::Parser;

my $feature = Test::BDD::Cucumber::Parser->parse_file(
	'examples/digest/features/basic.feature' );

# Check that we have three scenarios
my @scenarios = @{ $feature->scenarios };

for my $scenario_name (
	'Check MD5',
	'Check SHA-1',
	'MD5 longer data'
) {
	my $scenario = shift( @scenarios );
	ok( $scenario, "Scenario found" );
	is( $scenario->name || '', $scenario_name,
		"Scenario name matches: " . $scenario_name );
}

ok( $feature->background, "Background section exists" );

done_testing();