function filterTests(mTests, bIntegration, bRealOData) {
		var sUnwanted = bIntegration ? "full" : "integration",
			aTests,
			mFilter = {};

		aTests = Object.keys(mTests).filter(function (sUrl) {
			return mTests[sUrl] !== sUnwanted;
		});
		if (bIntegration) {
			// ensure that each URL has the query property "coverage"
			aTests = aTests.map(function (sUrl) {
				if (sUrl.indexOf("coverage") < 0) {
					sUrl = sUrl + (sUrl.indexOf("?") < 0 ? "?" : "&") + "coverage";
				}
				return sUrl;
			});
		}
		if (bRealOData === false) {
			// remove the query property "realOData" at each URL; remove duplicates
			aTests.forEach(function (sUrl) {
				var sTest = sUrl.replace(/\?.*$/, ""); // the URL w/o query parameters

				if (!mFilter[sTest]) {
					mFilter[sTest] = sUrl.replace(/realOData=true(&|$)/, "").replace(/[?&]$/, "");
				}
			});
			aTests = Object.keys(mFilter).map(function (sTest) {
				return mFilter[sTest];
			});
		} else if (bRealOData === true) {
			aTests = aTests.filter(function (sTest) {
				return /realOData=true/.test(sTest);
			});
		}
		return aTests;
	}
// returns an array of tests according to the given flags
returns an array of tests according to the given flags
returns an array of tests according to the given flags
function filterTests(mTests, bIntegration, bRealOData) {
		var sUnwanted = bIntegration ? "full" : "integration",
			aTests,
			mFilter = {};
		aTests = Object.keys(mTests).filter(function (sUrl) {
			return mTests[sUrl] !== sUnwanted;
		});
		if (bIntegration) {
			aTests = aTests.map(function (sUrl) {
				if (sUrl.indexOf("coverage") < 0) {
					sUrl = sUrl + (sUrl.indexOf("?") < 0 ? "?" : "&") + "coverage";
				}
				return sUrl;
			});
		}
		if (bRealOData === false) {
			aTests.forEach(function (sUrl) {
				var sTest = sUrl.replace(/\?.*$/, ""); 
				if (!mFilter[sTest]) {
					mFilter[sTest] = sUrl.replace(/realOData=true(&|$)/, "").replace(/[?&]$/, "");
				}
			});
			aTests = Object.keys(mFilter).map(function (sTest) {
				return mFilter[sTest];
			});
		} else if (bRealOData === true) {
			aTests = aTests.filter(function (sTest) {
				return /realOData=true/.test(sTest);
			});
		}
		return aTests;
	}
function filterTests ( mTests , bIntegration , bRealOData ) { var sUnwanted = bIntegration ? "full" : "integration" , aTests , mFilter = { } ; aTests = Object . keys ( mTests ) . filter ( function ( sUrl ) { return mTests [ sUrl ] !== sUnwanted ; } ) ; if ( bIntegration ) { aTests = aTests . map ( function ( sUrl ) { if ( sUrl . indexOf ( "coverage" ) < 0 ) { sUrl = sUrl + ( sUrl . indexOf ( "?" ) < 0 ? "?" : "&" ) + "coverage" ; } return sUrl ; } ) ; } if ( bRealOData === false ) { aTests . forEach ( function ( sUrl ) { var sTest = sUrl . replace ( / \?.*$ / , "" ) ; if ( ! mFilter [ sTest ] ) { mFilter [ sTest ] = sUrl . replace ( / realOData=true(&|$) / , "" ) . replace ( / [?&]$ / , "" ) ; } } ) ; aTests = Object . keys ( mFilter ) . map ( function ( sTest ) { return mFilter [ sTest ] ; } ) ; } else if ( bRealOData === true ) { aTests = aTests . filter ( function ( sTest ) { return / realOData=true / . test ( sTest ) ; } ) ; } return aTests ; }
returns an array of tests according to the given flags
returns an array of tests according to the given flags
// ensure that each URL has the query property "coverage" // remove the query property "realOData" at each URL; remove duplicates // the URL w/o query parameters