Sha256: 6644d3a336cc2211c6a3af7d340e4a27d9694ac030100841152066dd35a54475
Contents?: true
Size: 1.39 KB
Versions: 1
Compression:
Stored size: 1.39 KB
Contents
require File.expand_path(File.join(File.dirname(__FILE__), '..', '..', 'helper')) token = AuthToken.generate context "Mutating Ad Group" do setup do run_with_rescue do CityGrid::API::AdCenter::AdGroup.search(:token => token, :adGroupIds => 30966312) end end should("not be empty"){ !topic.empty? } should("have campaignId"){ !topic.adGroups.first.campaignId.nil? } end context "Search Ad Group by Campaign Id" do setup do run_with_rescue do CityGrid::API::AdCenter::AdGroup.search(:token => AuthToken.sales_coord, :campaignId => 2434702) end end should("not be empty"){ !topic.empty? } should("have campaignId"){ !topic.adGroups.first.campaignId.nil? } end context "Mutating Ad Group" do setup do run_with_rescue do CityGrid::API::AdCenter::AdGroup.mutate( :token => token, "mutateOperationListResource" => [{ "operator" => "ADD", "operand" => { "placeId" => "10728522", "campaignId" => "2435332", "contractTermMonths" =>"12", "monthlyServiceFee" => "19.95", "bids" => [{ "actionTargetName" => "map & directions", "ppe" => "1.80" }] } }] ) end end should("not be empty"){ !topic.empty? } should("have campaignId"){ !topic.adGroups.first.campaignId.nil? } end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
citygrid_api-0.0.5.1 | test/api/ad_center/test_ad_group.rb |