From 18933bf2aff859ce769e5a53a33ab700c20bc8f9 Mon Sep 17 00:00:00 2001 From: Wolfram Schneider Date: Mon, 16 Sep 2013 09:37:57 +0000 Subject: [PATCH] do not click on wikipedia source link - no author or subject facets possible --- test/spec/mkws-pazpar2.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/test/spec/mkws-pazpar2.js b/test/spec/mkws-pazpar2.js index 3296144..96df2ab 100644 --- a/test/spec/mkws-pazpar2.js +++ b/test/spec/mkws-pazpar2.js @@ -150,9 +150,15 @@ describe("Check Termlist", function () { it("limit search to first source", function () { var hits_all_targets = get_hit_counter(); + var source_number = 2; // 2=first source + var source_name = $("div#mkwsFacetSources div.term:nth-child(" + source_number + ") a").text(); + // do not click on wikipedia link - no author or subject facets possible + if (source_name.match(/wikipedia/i)) { + source_number++; + } - var click = $("div#mkwsFacetSources div.term:nth-child(2) a").trigger("click"); - debug("limit source click is success: " + click.length); + var click = $("div#mkwsFacetSources div.term:nth-child(" + source_number + ") a").trigger("click"); + debug("limit source click " + (source_number - 1) + " is success: " + click.length); expect(click.length).toBe(1); waitsFor(function () { -- 1.7.10.4