You are here

function dfpTokensTest::testSlotToken in Doubleclick for Publishers (DFP) 7

Same name and namespace in other branches
  1. 7.2 tests/dfp.test \dfpTokensTest::testSlotToken()

File

tests/dfp_tokens.test, line 20
Tokens test file for DFP module.

Class

dfpTokensTest
@file Tokens test file for DFP module.

Code

function testSlotToken() {
  $edit = $this
    ->dfpBasicTagEditValues();

  // Create a tag that uses the slot token in a target.
  $test_slot = $this
    ->randomName(8);
  $edit['slot'] = $test_slot;
  $edit['targeting[0][target]'] = 'slot';
  $edit['targeting[0][value]'] = '[dfp_tag:slot]';
  $tag = $this
    ->createTag($edit);
  $this
    ->assertPropertySet('Targeting', 'slot', $test_slot);
}