[Rt-commit] rtir branch, 3.4/cleanup-blocks, created. 3.3.0-173-g85afa57
Dustin Graves
dustin at bestpractical.com
Thu May 26 14:08:08 EDT 2016
The branch, 3.4/cleanup-blocks has been created
at 85afa57f4c80f699002797b13eb391860ac8f23e (commit)
- Log -----------------------------------------------------------------
commit 85afa57f4c80f699002797b13eb391860ac8f23e
Author: Dustin Graves <dustin at bestpractical.com>
Date: Thu May 26 18:08:01 2016 +0000
clean up remaining traces of Blocks after Blocks->Countermeasures change
diff --git a/docs/AdministrationTutorial.pod b/docs/AdministrationTutorial.pod
index 8e54bb0..6466618 100644
--- a/docs/AdministrationTutorial.pod
+++ b/docs/AdministrationTutorial.pod
@@ -45,20 +45,20 @@ of L</Scrips> below.
=head2 Custom Queues
-While RTIR ships with four queues by default--Incident Reports, Incidents,
-Investigations, and Blocks--you can create your own versions of these queues.
-This functionality (new in RTIR 3.4) is what powers the L<Constituencies>
-feature, but its use is not limited to Constituencies. For example you can have
-multiple queues for Incident Reports, one for each of your monitoring tools,
-each with its own set of custom fields, watchers, automation with scrips,
-templates, watchers, etc.
+While RTIR ships with four queues by default (Incident Reports, Incidents,
+Investigations, and Countermeasures) you can create your own versions of these
+queues. This functionality (new in RTIR 3.4) is what powers the
+L<Constituencies> feature, but its use is not limited to Constituencies. For
+example you can have multiple queues for Incident Reports, one for each of your
+monitoring tools, each with its own set of custom fields, watchers, automation
+with scrips, templates, watchers, etc.
To create a new RTIR queue, visit RT's Admin -> Queue -> Create menu. Create
the queue as normal, but be sure to select an RTIR lifecycle (incident_reports,
-incidents, investigations, or blocks). By doing so you include the queue into
-the RTIR system. After creating the queue, it will be available throughout RTIR
-alongside the four builtin incident response queues. Assign custom fields,
-watchers, etc. as desired.
+incidents, investigations, or countermeasures). By doing so you include the
+queue into the RTIR system. After creating the queue, it will be available
+throughout RTIR alongside the four builtin incident response queues. Assign
+custom fields, watchers, etc. as desired.
=head2 Custom Fields
diff --git a/etc/RTIR_Config.pm b/etc/RTIR_Config.pm
index cc15f94..dfeb340 100644
--- a/etc/RTIR_Config.pm
+++ b/etc/RTIR_Config.pm
@@ -609,7 +609,7 @@ Set($RTIR_DisableCountermeasures, 0);
=item C<$RTIR_CountermeasureApproveActionRegexp>
-When requestor replies on the block in pending state RTIR
+When requestor replies on the countermeasure in pending state RTIR
changes state, you can set regular expresion so state would
be changed only when content matches the regexp.
diff --git a/etc/initialdata b/etc/initialdata
index 9538b0d..9eb62c5 100644
--- a/etc/initialdata
+++ b/etc/initialdata
@@ -379,7 +379,7 @@ die "Please add RT::IR to your Plugins configuration before initializing the dat
@Templates = (
{ Queue => 'Countermeasures',
Name => 'Autoreply',
- Description => 'Sent when a block is created',
+ Description => 'Sent when a countermeasure is created',
Content => 'RT-Attach-Message: yes
Subject: { $Ticket->Subject }
diff --git a/html/Callbacks/RTIR/Elements/MakeClicky/Default b/html/Callbacks/RTIR/Elements/MakeClicky/Default
index 24ddddb..2b08856 100644
--- a/html/Callbacks/RTIR/Elements/MakeClicky/Default
+++ b/html/Callbacks/RTIR/Elements/MakeClicky/Default
@@ -105,9 +105,9 @@ my %actions;
my $result .= qq{<a class="button" href="}. RT::IR->HREFTo("Tools/Lookup.html?".$args{lookup_params}."type=ip&q=".$escaped_host).qq{">}
.loc('Lookup IP') .q{</a>};
if ( $args{incident} && !RT->Config->Get('RTIR_DisableCountermeasures') ) {
- $result .= qq{<a class="button create_child_blocks" href="} .
+ $result .= qq{<a class="button create_child_} . RT::IR->lifecycle_countermeasure . qq{" href="} .
RT::IR->HREFTo("CreateInQueue.html?Incident=".$args{incident}."&Lifecycle=".RT::IR->lifecycle_countermeasure.qq{&IP-Value=$escaped_host})
- .qq{">block</a>};
+ .qq{">Block</a>};
}
if ( $args{'object'} && $args{'object'}->id ) {
my $cf = RT::IR::GetCustomField('IP');
diff --git a/html/Callbacks/RTIR/Elements/RT__Ticket/ColumnMap/Once b/html/Callbacks/RTIR/Elements/RT__Ticket/ColumnMap/Once
index 0cef225..495ce87 100644
--- a/html/Callbacks/RTIR/Elements/RT__Ticket/ColumnMap/Once
+++ b/html/Callbacks/RTIR/Elements/RT__Ticket/ColumnMap/Once
@@ -155,7 +155,7 @@ $COLUMN_MAP->{'LookupToolIncidentActions'} = {
push @res, \'<a href="',
RT::IR->HREFTo('CreateInQueue.html?Lifecycle='.RT::IR->lifecycle_investigation
.'&Incident='. $t->id),
- \'" class="create_child_blocks">',
+ \'" class="create_child_' . RT::IR->lifecycle_investigation . '">',
'[' . $t->loc("Investigate") .']',
\'</a>'
;
diff --git a/t/countermeasure/pending-no-regexp.t b/t/countermeasure/pending-no-regexp.t
index c08718d..429516c 100644
--- a/t/countermeasure/pending-no-regexp.t
+++ b/t/countermeasure/pending-no-regexp.t
@@ -10,50 +10,50 @@ RT->Config->Set('RTIR_CountermeasureApproveActionRegexp', undef);
RT::Test->started_ok;
my $agent = default_agent();
-my $inc_id = $agent->create_incident( {Subject => "incident with block"});
+my $inc_id = $agent->create_incident( {Subject => "incident with countermeasure"});
my $rtname = RT->Config->Get('rtname');
-my $block_id = $agent->create_countermeasure( {
- Subject => "block",
+my $countermeasure_id = $agent->create_countermeasure( {
+ Subject => "countermeasure",
Incident => $inc_id,
Requestors => 'rt-test at example.com',
} );
-$agent->ticket_status_is( $block_id, 'pending activation');
+$agent->ticket_status_is( $countermeasure_id, 'pending activation');
{
my $text = <<EOF;
From: rt-test\@example.com
To: rt\@@{[RT->Config->Get('rtname')]}
-Subject: [$rtname #$block_id] This is a test
+Subject: [$rtname #$countermeasure_id] This is a test
test
EOF
my ($status, $id) = RT::Test->send_via_mailgate($text, queue => 'Countermeasures');
is $status >> 8, 0, "The mail gateway exited ok";
- is $id, $block_id, "replied to the ticket";
- $agent->ticket_status_is( $block_id, 'active');
+ is $id, $countermeasure_id, "replied to the ticket";
+ $agent->ticket_status_is( $countermeasure_id, 'active');
}
{
- $agent->display_ticket( $block_id);
+ $agent->display_ticket( $countermeasure_id);
$agent->follow_link_ok({ text => 'Pending Removal' }, "-> pending removal");
$agent->form_number(3);
$agent->field( UpdateContent => 'going to remove' );
$agent->click('SubmitTicket');
- $agent->ticket_status_is( $block_id, 'pending removal');
+ $agent->ticket_status_is( $countermeasure_id, 'pending removal');
}
{
my $text = <<EOF;
From: rt-test\@example.com
To: rt\@@{[RT->Config->Get('rtname')]}
-Subject: [$rtname #$block_id] This is a test
+Subject: [$rtname #$countermeasure_id] This is a test
some text
EOF
my ($status, $id) = RT::Test->send_via_mailgate($text, queue => 'Countermeasures');
is $status >> 8, 0, "The mail gateway exited ok";
- is $id, $block_id, "replied to the ticket";
- $agent->ticket_status_is( $block_id, 'removed');
+ is $id, $countermeasure_id, "replied to the ticket";
+ $agent->ticket_status_is( $countermeasure_id, 'removed');
}
undef $agent;
diff --git a/t/countermeasure/pending-regexp.t b/t/countermeasure/pending-regexp.t
index 2c2b022..7edf0b1 100644
--- a/t/countermeasure/pending-regexp.t
+++ b/t/countermeasure/pending-regexp.t
@@ -5,86 +5,86 @@ use warnings;
use RT::IR::Test tests => undef;
-RT->Config->Set('RTIR_CountermeasureApproveActionRegexp', qr/TestPendingBlock/);
+RT->Config->Set('RTIR_CountermeasureApproveActionRegexp', qr/TestPendingCountermeasure/);
RT::Test->started_ok;
my $agent = default_agent();
my $rtname = RT->Config->Get('rtname');
-my $inc_id = $agent->create_incident( {Subject => "incident with block"});
-my $block_id = $agent->create_countermeasure( {
- Subject => "block",
+my $inc_id = $agent->create_incident( {Subject => "incident with countermeasure"});
+my $countermeasure_id = $agent->create_countermeasure( {
+ Subject => "countermeasure",
Incident => $inc_id,
Requestors => 'rt-test at example.com',
} );
-$agent->ticket_status_is( $block_id, 'pending activation');
+$agent->ticket_status_is( $countermeasure_id, 'pending activation');
{
my $text = <<EOF;
From: rt-test\@example.com
To: rt\@@{[RT->Config->Get('rtname')]}
-Subject: [$rtname #$block_id] This is a test
+Subject: [$rtname #$countermeasure_id] This is a test
some text
EOF
my ($status, $id) = RT::Test->send_via_mailgate($text, queue => 'Countermeasures');
is $status >> 8, 0, "The mail gateway exited ok";
- is $id, $block_id, "replied to the ticket";
- $agent->ticket_status_is( $block_id, 'pending activation');
+ is $id, $countermeasure_id, "replied to the ticket";
+ $agent->ticket_status_is( $countermeasure_id, 'pending activation');
}
{
my $text = <<EOF;
From: rt-test\@example.com
To: rt\@@{[RT->Config->Get('rtname')]}
-Subject: [$rtname #$block_id] This is a test
+Subject: [$rtname #$countermeasure_id] This is a test
-TestPendingBlock
+TestPendingCountermeasure
EOF
my ($status, $id) = RT::Test->send_via_mailgate($text, queue => 'Countermeasures');
is $status >> 8, 0, "The mail gateway exited ok";
- is $id, $block_id, "replied to the ticket";
- $agent->ticket_status_is( $block_id, 'active');
+ is $id, $countermeasure_id, "replied to the ticket";
+ $agent->ticket_status_is( $countermeasure_id, 'active');
}
{
- $agent->display_ticket( $block_id);
+ $agent->display_ticket( $countermeasure_id);
$agent->follow_link_ok({ text => 'Pending Removal' }, "-> pending removal");
$agent->form_number(3);
$agent->field( UpdateContent => 'going to remove' );
$agent->click('SubmitTicket');
- $agent->ticket_status_is( $block_id, 'pending removal');
+ $agent->ticket_status_is( $countermeasure_id, 'pending removal');
}
{
my $text = <<EOF;
From: rt-test\@example.com
To: rt\@@{[RT->Config->Get('rtname')]}
-Subject: [$rtname #$block_id] This is a test
+Subject: [$rtname #$countermeasure_id] This is a test
some text
EOF
my ($status, $id) = RT::Test->send_via_mailgate($text, queue => 'Countermeasures');
is $status >> 8, 0, "The mail gateway exited ok";
- is $id, $block_id, "replied to the ticket";
- $agent->ticket_status_is( $block_id, 'pending removal');
+ is $id, $countermeasure_id, "replied to the ticket";
+ $agent->ticket_status_is( $countermeasure_id, 'pending removal');
}
{
my $text = <<EOF;
From: rt-test\@example.com
To: rt\@@{[RT->Config->Get('rtname')]}
-Subject: [$rtname #$block_id] This is a test
+Subject: [$rtname #$countermeasure_id] This is a test
-TestPendingBlock
+TestPendingCountermeasure
EOF
my ($status, $id) = RT::Test->send_via_mailgate($text, queue => 'Countermeasures');
is $status >> 8, 0, "The mail gateway exited ok";
- is $id, $block_id, "replied to the ticket";
- $agent->ticket_status_is( $block_id, 'removed');
+ is $id, $countermeasure_id, "replied to the ticket";
+ $agent->ticket_status_is( $countermeasure_id, 'removed');
}
undef $agent;
diff --git a/t/countermeasure/status-basics.t b/t/countermeasure/status-basics.t
index 7489460..a48ba5b 100644
--- a/t/countermeasure/status-basics.t
+++ b/t/countermeasure/status-basics.t
@@ -8,10 +8,10 @@ use RT::IR::Test tests => undef;
RT::Test->started_ok;
my $agent = default_agent();
-my $inc_id = $agent->create_incident( {Subject => "incident with block"});
-my $block_id = $agent->create_countermeasure( {Subject => "block", Incident => $inc_id});
+my $inc_id = $agent->create_incident( {Subject => "incident with countermeasure"});
+my $countermeasure_id = $agent->create_countermeasure( {Subject => "countermeasure", Incident => $inc_id});
-$agent->ticket_status_is( $block_id, 'pending activation');
+$agent->ticket_status_is( $countermeasure_id, 'pending activation');
$agent->has_tag('a', 'Remove', 'we have Remove action');
$agent->has_tag('a', 'Quick Remove', 'we have Quick Remove action');
@@ -22,7 +22,7 @@ foreach my $status( 'pending activation', 'active', 'pending removal', 'removed'
$agent->form_number(3);
$agent->field(Status => $status);
$agent->click('SaveChanges');
- $agent->ticket_status_is( $block_id, $status);
+ $agent->ticket_status_is( $countermeasure_id, $status);
}
diag "remove using edit";
@@ -37,68 +37,68 @@ diag "remove using edit";
$agent->field(Status => 'removed');
$agent->click('SaveChanges');
- $agent->ticket_status_is( $block_id, 'removed');
+ $agent->ticket_status_is( $countermeasure_id, 'removed');
}
-diag "reactivate the block using the link";
+diag "reactivate the countermeasure using the link";
{
$agent->has_tag('a', 'Activate', 'we have Activate action');
- $agent->follow_link_ok({ text => 'Activate' }, "Reactivate block");
+ $agent->follow_link_ok({ text => 'Activate' }, "Reactivate countermeasure");
$agent->form_number(3);
- $agent->field( UpdateContent => 'activating block' );
+ $agent->field( UpdateContent => 'activating countermeasure' );
$agent->click('SubmitTicket');
- $agent->ticket_status_is( $block_id, 'active');
+ $agent->ticket_status_is( $countermeasure_id, 'active');
}
diag "prepare for removing using the link";
{
$agent->has_tag('a', 'Pending Removal', 'we have Pending Removal action tab');
- $agent->follow_link_ok({ text => 'Pending Removal' }, "Prepare block for remove");
+ $agent->follow_link_ok({ text => 'Pending Removal' }, "Prepare countermeasure for remove");
$agent->form_number(3);
$agent->click('SubmitTicket');
- $agent->ticket_status_is( $block_id, 'pending removal');
+ $agent->ticket_status_is( $countermeasure_id, 'pending removal');
}
diag "test activation after reply using 'Activate' link";
{
- my $block_id = $agent->create_countermeasure( {Subject => "block", Incident => $inc_id});
- $agent->ticket_status_is( $block_id, 'pending activation');
+ my $countermeasure_id = $agent->create_countermeasure( {Subject => "countermeasure", Incident => $inc_id});
+ $agent->ticket_status_is( $countermeasure_id, 'pending activation');
$agent->follow_link_ok({ text => 'Reply' }, "Go to reply page");
$agent->form_number(3);
$agent->field( UpdateContent => 'reply' );
$agent->click('SubmitTicket');
- $agent->ticket_status_is( $block_id, 'pending activation');
+ $agent->ticket_status_is( $countermeasure_id, 'pending activation');
$agent->follow_link_ok({ text => 'Activate' }, "activate it");
$agent->form_number(3);
- $agent->field( UpdateContent => 'activating block' );
+ $agent->field( UpdateContent => 'activating countermeasure' );
$agent->click('SubmitTicket');
- $agent->ticket_status_is( $block_id, 'active');
+ $agent->ticket_status_is( $countermeasure_id, 'active');
}
diag "test activation after reply using Edit page";
{
- my $block_id = $agent->create_countermeasure( {Subject => "block", Incident => $inc_id});
- $agent->ticket_status_is( $block_id, 'pending activation');
+ my $countermeasure_id = $agent->create_countermeasure( {Subject => "countermeasure", Incident => $inc_id});
+ $agent->ticket_status_is( $countermeasure_id, 'pending activation');
$agent->follow_link_ok({ text => 'Reply' }, "Go to reply page");
$agent->form_number(3);
$agent->field( UpdateContent => 'reply' );
$agent->click('SubmitTicket');
- $agent->ticket_status_is( $block_id, 'pending activation');
+ $agent->ticket_status_is( $countermeasure_id, 'pending activation');
$agent->follow_link_ok({ text => "Edit" }, "Goto edit page");
$agent->form_number(3);
$agent->field(Status => 'active');
$agent->click('SaveChanges');
- $agent->ticket_status_is( $block_id, 'active');
+ $agent->ticket_status_is( $countermeasure_id, 'active');
}
diff --git a/t/countermeasure/status-editor-regression.t b/t/countermeasure/status-editor-regression.t
index 80eb97c..927a637 100644
--- a/t/countermeasure/status-editor-regression.t
+++ b/t/countermeasure/status-editor-regression.t
@@ -8,10 +8,10 @@ use RT::IR::Test tests => undef;
RT::Test->started_ok;
my $agent = default_agent();
-my $incident = $agent->create_incident( {Subject => 'Incident to test Block editing'});
-my $block = $agent->create_countermeasure( {Incident => $incident});
+my $incident = $agent->create_incident( {Subject => 'Incident to test Countermeasure editing'});
+my $countermeasure = $agent->create_countermeasure( {Incident => $incident});
-$agent->goto_edit_countermeasure( $block);
+$agent->goto_edit_countermeasure( $countermeasure);
$agent->content_unlike(qr{<option (?:value=.*)?>Use system default\(\)</option>}, "The option 'Use system default()' does not exist.");
diff --git a/t/custom-fields/defaults-config.t b/t/custom-fields/defaults-config.t
index d8b330b..4289e0c 100644
--- a/t/custom-fields/defaults-config.t
+++ b/t/custom-fields/defaults-config.t
@@ -29,7 +29,7 @@ RT::Test->started_ok;
my $agent = default_agent();
{
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
my $cf_name = $test_on{ $queue };
my $cf_default = $defaults->{ $cf_name };
diff --git a/t/custom-fields/ip.t b/t/custom-fields/ip.t
index 45097ce..feea212 100644
--- a/t/custom-fields/ip.t
+++ b/t/custom-fields/ip.t
@@ -40,7 +40,7 @@ my $rtir_user = RT::CurrentUser->new( rtir_user() );
diag "create a ticket via web and set IP" if $ENV{'TEST_VERBOSE'};
{
my $i = 0;
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
@@ -67,7 +67,7 @@ diag "create a ticket via web and set IP" if $ENV{'TEST_VERBOSE'};
diag "create a ticket via web with IP in message" if $ENV{'TEST_VERBOSE'};
{
my $i = 0;
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
@@ -94,7 +94,7 @@ diag "create a ticket via web with IP in message" if $ENV{'TEST_VERBOSE'};
diag "create a ticket via web with CIDR" if $ENV{'TEST_VERBOSE'};
{
my $i = 0;
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
@@ -124,7 +124,7 @@ diag "create a ticket via web with CIDR" if $ENV{'TEST_VERBOSE'};
diag "create a ticket via web with CIDR in message" if $ENV{'TEST_VERBOSE'};
{
my $i = 0;
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
@@ -154,7 +154,7 @@ diag "create a ticket via web with CIDR in message" if $ENV{'TEST_VERBOSE'};
diag "create a ticket and edit IP field using Edit page" if $ENV{'TEST_VERBOSE'};
{
my $i = 0;
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
diff --git a/t/custom-fields/ipv6.t b/t/custom-fields/ipv6.t
index 3ffd335..afd3b4c 100644
--- a/t/custom-fields/ipv6.t
+++ b/t/custom-fields/ipv6.t
@@ -77,7 +77,7 @@ diag "create a ticket via web and set IP" if $ENV{'TEST_VERBOSE'};
for my $short (sort keys %valid) {
my $full = $valid{$short};
my $abbrev = $abbrev_of{$short};
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
@@ -104,7 +104,7 @@ diag "create a ticket via web with IP in message" if $ENV{'TEST_VERBOSE'};
for my $short (sort keys %test_set) {
my $full = $valid{$short};
my $abbrev = $abbrev_of{$short};
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
@@ -131,7 +131,7 @@ diag "create a ticket via web with CIDR" if $ENV{'TEST_VERBOSE'};
for my $short (sort keys %test_cidr) {
my $full = $test_cidr{$short};
my $abbrev = $abbrev_of{$short};
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
@@ -162,7 +162,7 @@ for my $short (sort keys %test_cidr) {
my $full = $test_cidr{$short};
my $abbrev = $abbrev_of{$short};
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
@@ -191,7 +191,7 @@ for my $short (sort keys %test_cidr) {
diag "create a ticket and edit IP field using Edit page" if $ENV{'TEST_VERBOSE'};
{
my $i = 0;
- my $incident_id; # block couldn't be created without incident id
+ my $incident_id; # countermeasure couldn't be created without incident id
foreach my $queue( 'Incidents', 'Incident Reports', 'Investigations', 'Countermeasures' ) {
diag "create a ticket in the '$queue' queue" if $ENV{'TEST_VERBOSE'};
diff --git a/t/dates/started.t b/t/dates/started.t
index a34ebc0..06c1494 100644
--- a/t/dates/started.t
+++ b/t/dates/started.t
@@ -82,31 +82,31 @@ diag "started date of an IR" if $ENV{'TEST_VERBOSE'};
ok( abs($ir->StartedObj->Unix - $ir->CreatedObj->Unix) <= 2, 'for an IR started date == linking to inc time');
}
-diag "started date of a block" if $ENV{'TEST_VERBOSE'};
+diag "started date of a countermeasure" if $ENV{'TEST_VERBOSE'};
{
my $inc_id = $agent->create_incident( {Subject => "started date"});
- my $block_id = $agent->create_countermeasure( {Subject => "started date", Incident => $inc_id});
+ my $countermeasure_id = $agent->create_countermeasure( {Subject => "started date", Incident => $inc_id});
- my $block = RT::Ticket->new( $RT::SystemUser );
- $block->Load( $block_id );
- is($block->id, $block_id, 'loaded block');
- ok( $block->StartedObj->Unix <= 0, 'a new block is not active');
+ my $countermeasure = RT::Ticket->new( $RT::SystemUser );
+ $countermeasure->Load( $countermeasure_id );
+ is($countermeasure->id, $countermeasure_id, 'loaded countermeasure');
+ ok( $countermeasure->StartedObj->Unix <= 0, 'a new countermeasure is not active');
- $agent->display_ticket( $block_id);
+ $agent->display_ticket( $countermeasure_id);
$agent->follow_link_ok({text => 'Activate'}, "activate it");
is($agent->status, 200, "request successful");
$agent->form_number(3);
- $agent->field( UpdateContent => 'activating block' );
+ $agent->field( UpdateContent => 'activating countermeasure' );
$agent->click('SubmitTicket');
is($agent->status, 200, "request successful");
DBIx::SearchBuilder::Record::Cachable::FlushCache();
- $block = RT::Ticket->new( $RT::SystemUser );
- $block->Load( $block_id );
- is($block->id, $block_id, 'loaded block');
- ok( $block->StartedObj->Unix > 0, 'activation of a block sets started date');
+ $countermeasure = RT::Ticket->new( $RT::SystemUser );
+ $countermeasure->Load( $countermeasure_id );
+ is($countermeasure->id, $countermeasure_id, 'loaded countermeasure');
+ ok( $countermeasure->StartedObj->Unix > 0, 'activation of a countermeasure sets started date');
}
diff --git a/t/walk-web.t b/t/walk-web.t
index eb0a454..8d27daa 100644
--- a/t/walk-web.t
+++ b/t/walk-web.t
@@ -16,7 +16,7 @@ my @tickets;
push @tickets, $m->create_incident({ Subject => "test Incident" });
push @tickets, $m->create_ir({ Subject => "test IR" });
push @tickets, $m->create_investigation({ Subject => "test Inv", Requestor => 'root at example.com' });
-push @tickets, $m->create_countermeasure({ Subject => "test Block", Incident => $tickets[0] });
+push @tickets, $m->create_countermeasure({ Subject => "test Countermeasure", Incident => $tickets[0] });
my @links = (
'/RTIR/',
-----------------------------------------------------------------------
More information about the rt-commit
mailing list