diff --git a/src/AxaFrance.AxeExtended.HtmlReport/OverallReportBuilder.cs b/src/AxaFrance.AxeExtended.HtmlReport/OverallReportBuilder.cs
index dad7791..4d0327c 100644
--- a/src/AxaFrance.AxeExtended.HtmlReport/OverallReportBuilder.cs
+++ b/src/AxaFrance.AxeExtended.HtmlReport/OverallReportBuilder.cs
@@ -136,7 +136,8 @@ public string Export(string fileName = null)
//Add tags
ruleResults.AppendLine($"
");
- var additionalTags = options.AdditionalTags?.GetTagsByRule(ruleId);
+ /*
+ var additionalTags = options.AdditionalTags?.GetTagsByRule(rule.Key);
if (additionalTags != null)
{
foreach (var tag in additionalTags)
@@ -144,7 +145,9 @@ public string Export(string fileName = null)
ruleResults.AppendLine($"{tag}");
}
}
+ */
ruleResults.AppendLine($" | ");
+
foreach (var page in Result.PageResults)
{
if (Array.Find(page.Violations, x => x.Item.Id == ruleId) != null)
diff --git a/src/AxaFrance.AxeExtended.HtmlReport/PageReportBuilder.cs b/src/AxaFrance.AxeExtended.HtmlReport/PageReportBuilder.cs
index 7123b4b..c6c2d1a 100644
--- a/src/AxaFrance.AxeExtended.HtmlReport/PageReportBuilder.cs
+++ b/src/AxaFrance.AxeExtended.HtmlReport/PageReportBuilder.cs
@@ -260,7 +260,7 @@ private string GenerateRuleSection(AxeResultEnhancedItem[] items, string path)
);
}
string tags = string.Join(" ", item.Item.Tags.Select(x => $"{x}
"));
- var additinalTags = Options.AdditionalTags?.GetTagsByRule(item.Item.Id);
+ var additinalTags = Options.AdditionalTags?.GetTagsByRule(item.Item);
if (additinalTags != null)
{
tags += string.Join(" ", additinalTags.Select(x => $"{x}
"));
diff --git a/src/AxaFrance.AxeExtended.HtmlReport/PageReportOptions.cs b/src/AxaFrance.AxeExtended.HtmlReport/PageReportOptions.cs
index f8f8603..64b1724 100644
--- a/src/AxaFrance.AxeExtended.HtmlReport/PageReportOptions.cs
+++ b/src/AxaFrance.AxeExtended.HtmlReport/PageReportOptions.cs
@@ -28,10 +28,10 @@ public sealed class PageReportOptions
public Language ReportLanguage { get; set; } = Language.English;
///
- /// In the report, show the RGAA tags (equivalent RGAA Test Methdologie) for each rule. Default is true.
+ /// In the report, show additional tags
/// Default value: will use additional tags provider to get equivalent RGAA test tags.
///
- public AdditionalTagsProvider AdditionalTags { get; set; } = new RgaaTagsProvider();
+ public TagsProvider AdditionalTags { get; set; } = new WcagTagsProvider();
///
/// Gets or sets the value indicating if advanced screenshot should be used. Default is true.
diff --git a/src/AxaFrance.AxeExtended.HtmlReport/RgaaTagsProvider.cs b/src/AxaFrance.AxeExtended.HtmlReport/RgaaTagsProvider.cs
index 64239d2..35262d0 100644
--- a/src/AxaFrance.AxeExtended.HtmlReport/RgaaTagsProvider.cs
+++ b/src/AxaFrance.AxeExtended.HtmlReport/RgaaTagsProvider.cs
@@ -1,4 +1,5 @@
-using System;
+using Deque.AxeCore.Commons;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
@@ -11,7 +12,7 @@ namespace AxaFrance.AxeExtended.HtmlReport
/// A mapping of Axe rules to RGAA rules, for future use
/// refers to the Mapping Rules Excel file
///
- internal class RgaaTagsProvider : AdditionalTagsProvider
+ internal class RgaaTagsProvider : TagsProvider
{
private static Dictionary> Mapping { get; } = new Dictionary>()
@@ -73,9 +74,9 @@ internal class RgaaTagsProvider : AdditionalTagsProvider
{"table-fake-caption", new string[] {"RGAA 5.1.1"}},
};
- public override IEnumerable GetTagsByRule(string ruleId)
+ public override IEnumerable GetTagsByRule(AxeResultItem rule)
{
-
+ var ruleId = rule.Id;
if (Mapping.ContainsKey(ruleId))
{
return Mapping[ruleId];
diff --git a/src/AxaFrance.AxeExtended.HtmlReport/AdditionalTagsProvider.cs b/src/AxaFrance.AxeExtended.HtmlReport/TagsProvider.cs
similarity index 57%
rename from src/AxaFrance.AxeExtended.HtmlReport/AdditionalTagsProvider.cs
rename to src/AxaFrance.AxeExtended.HtmlReport/TagsProvider.cs
index c72c1c8..4dd3c8d 100644
--- a/src/AxaFrance.AxeExtended.HtmlReport/AdditionalTagsProvider.cs
+++ b/src/AxaFrance.AxeExtended.HtmlReport/TagsProvider.cs
@@ -1,4 +1,5 @@
-using System;
+using Deque.AxeCore.Commons;
+using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
@@ -9,13 +10,19 @@ namespace AxaFrance.AxeExtended.HtmlReport
///
/// The provider to get additional tags for a rule.
///
- public abstract class AdditionalTagsProvider
+ public abstract class TagsProvider
{
///
/// return a list of additional tags for a rule. if the rule is not found, return an empty list.
///
/// the identifier of the rule
/// a list of additional tags for a given rule.
- public abstract IEnumerable GetTagsByRule(string ruleId);
+ public abstract IEnumerable GetTagsByRule(AxeResultItem rule);
+
+ ///
+ /// If additional tags should be shown only on overall report.
+ /// The value is determined by tags provider
+ ///
+ public bool ShowOnOverallReportOnly { get; internal set; }
}
}
diff --git a/src/AxaFrance.AxeExtended.HtmlReport/WcagTagsProvider.cs b/src/AxaFrance.AxeExtended.HtmlReport/WcagTagsProvider.cs
new file mode 100644
index 0000000..12defd3
--- /dev/null
+++ b/src/AxaFrance.AxeExtended.HtmlReport/WcagTagsProvider.cs
@@ -0,0 +1,23 @@
+using Deque.AxeCore.Commons;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace AxaFrance.AxeExtended.HtmlReport
+{
+ internal class WcagTagsProvider : TagsProvider
+ {
+ public override IEnumerable GetTagsByRule(AxeResultItem rule)
+ {
+ foreach (var tag in rule.Tags)
+ {
+ if(tag.StartsWith("wcag"))
+ {
+ yield return tag;
+ }
+ }
+ }
+ }
+}
diff --git a/src/AxaFrance.WebEngine.MobileApp/AppFactory.cs b/src/AxaFrance.WebEngine.MobileApp/AppFactory.cs
index 33b48bf..a2e3c29 100644
--- a/src/AxaFrance.WebEngine.MobileApp/AppFactory.cs
+++ b/src/AxaFrance.WebEngine.MobileApp/AppFactory.cs
@@ -5,6 +5,7 @@
using OpenQA.Selenium.Appium;
using OpenQA.Selenium.Appium.Android;
using OpenQA.Selenium.Appium.iOS;
+using OpenQA.Selenium.Remote;
using System;
using System.Collections.Generic;
using System.IO;
@@ -230,10 +231,11 @@ private static AppiumDriver ConnectToDevice()
options.AddAdditionalAppiumOption("newCommandTimeout", 90);
options.AddAdditionalAppiumOption("nativeWebScreenshot", true);
+ options.AcceptInsecureCertificates = s.AllowAnyCertificate;
if (!string.IsNullOrEmpty(s.OsVersion))
{
- options.AddAdditionalAppiumOption("os_version", s.OsVersion);
+ options.PlatformVersion = s.OsVersion;
}
@@ -258,12 +260,14 @@ private static AppiumDriver ConnectToDevice()
if (s.Platform == Platform.Android)
{
options.AutomationName = "UiAutomator2";
- driver = new AndroidDriver(new Uri(appiumServerAddress), options);
+ driver = new AndroidDriver(new Uri(appiumServerAddress), options, TimeSpan.FromSeconds(180));
}
else if (s.Platform == Platform.iOS)
{
options.AutomationName = "XCUITest";
- driver = new IOSDriver(new Uri(appiumServerAddress), options);
+ options.AddAdditionalAppiumOption("includeSafariInWebviews", true);
+ options.AddAdditionalAppiumOption("connectHardwareKeyboard", true);
+ driver = new IOSDriver(new Uri(appiumServerAddress), options, TimeSpan.FromSeconds(180));
}
else
{
diff --git a/src/AxaFrance.WebEngine.MobileApp/AxaFrance.WebEngine.MobileApp.csproj b/src/AxaFrance.WebEngine.MobileApp/AxaFrance.WebEngine.MobileApp.csproj
index 4da2dae..ed58dd4 100644
--- a/src/AxaFrance.WebEngine.MobileApp/AxaFrance.WebEngine.MobileApp.csproj
+++ b/src/AxaFrance.WebEngine.MobileApp/AxaFrance.WebEngine.MobileApp.csproj
@@ -20,9 +20,9 @@
-
+
-
+
diff --git a/src/AxaFrance.WebEngine.ReportViewer/MainWindow.xaml b/src/AxaFrance.WebEngine.ReportViewer/MainWindow.xaml
index 21483c4..4c2a3c5 100644
--- a/src/AxaFrance.WebEngine.ReportViewer/MainWindow.xaml
+++ b/src/AxaFrance.WebEngine.ReportViewer/MainWindow.xaml
@@ -25,7 +25,8 @@
-
+
+