@arghajit/dummy 0.3.17 → 0.3.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +93 -85
- package/dist/reporter/playwright-pulse-reporter.d.ts +1 -0
- package/dist/reporter/playwright-pulse-reporter.js +41 -2
- package/dist/types/index.d.ts +2 -1
- package/package.json +7 -3
- package/scripts/generate-email-report.mjs +5 -2
- package/scripts/generate-report.mjs +405 -255
- package/scripts/generate-static-report.mjs +406 -218
- package/scripts/merge-pulse-report.js +9 -1
- package/scripts/sendReport.mjs +3 -0
- package/scripts/terminal-logo.mjs +51 -0
|
@@ -6,6 +6,7 @@ import path from "path";
|
|
|
6
6
|
import { fork } from "child_process";
|
|
7
7
|
import { fileURLToPath } from "url";
|
|
8
8
|
import { getOutputDir } from "./config-reader.mjs";
|
|
9
|
+
import { animate } from "./terminal-logo.mjs";
|
|
9
10
|
|
|
10
11
|
// Use dynamic import for chalk as it's ESM only
|
|
11
12
|
let chalk;
|
|
@@ -688,21 +689,173 @@ function generatePieChart(data, chartWidth = 300, chartHeight = 300) {
|
|
|
688
689
|
</div>
|
|
689
690
|
`;
|
|
690
691
|
}
|
|
691
|
-
function
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
692
|
+
function generateEnvironmentSection(environmentData) {
|
|
693
|
+
if (!environmentData) {
|
|
694
|
+
return '<div class="no-data">Environment data not available.</div>';
|
|
695
|
+
}
|
|
696
|
+
|
|
697
|
+
if (Array.isArray(environmentData)) {
|
|
698
|
+
return `
|
|
699
|
+
<div class="sharded-env-section">
|
|
700
|
+
<div class="sharded-env-header">
|
|
701
|
+
<div class="sharded-env-title-row">
|
|
702
|
+
<div>
|
|
703
|
+
<div class="sharded-env-title">
|
|
704
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
705
|
+
<rect width="20" height="8" x="2" y="2" rx="2" ry="2"></rect>
|
|
706
|
+
<rect width="20" height="8" x="2" y="14" rx="2" ry="2"></rect>
|
|
707
|
+
<line x1="6" x2="6.01" y1="6" y2="6"></line>
|
|
708
|
+
<line x1="6" x2="6.01" y1="18" y2="18"></line>
|
|
709
|
+
</svg>
|
|
710
|
+
System Information
|
|
711
|
+
</div>
|
|
712
|
+
<div class="sharded-env-subtitle">Test execution environment details - ${environmentData.length} shard${environmentData.length > 1 ? "s" : ""}</div>
|
|
713
|
+
</div>
|
|
714
|
+
<div class="env-icon-badge">
|
|
715
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
716
|
+
<path d="M20 16V7a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v9m16 0H4m16 0 1.28 2.55a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45L4 16"></path>
|
|
717
|
+
</svg>
|
|
718
|
+
</div>
|
|
719
|
+
</div>
|
|
720
|
+
</div>
|
|
721
|
+
<div class="sharded-environments-container">
|
|
722
|
+
<div class="sharded-environments-wrapper">
|
|
723
|
+
${environmentData
|
|
724
|
+
.map(
|
|
725
|
+
(env, index) => `
|
|
726
|
+
<div class="env-card-wrapper">
|
|
727
|
+
<div class="env-card-badge">Shard ${index + 1}</div>
|
|
728
|
+
${generateEnvironmentDashboard(env, true)}
|
|
729
|
+
</div>
|
|
730
|
+
`,
|
|
731
|
+
)
|
|
732
|
+
.join("")}
|
|
733
|
+
</div>
|
|
734
|
+
</div>
|
|
735
|
+
</div>
|
|
736
|
+
<style>
|
|
737
|
+
.sharded-env-section {
|
|
738
|
+
border: 1px solid #e2e8f0;
|
|
739
|
+
border-radius: 12px;
|
|
740
|
+
background: #fafbfc;
|
|
741
|
+
overflow: hidden;
|
|
742
|
+
}
|
|
743
|
+
.sharded-env-header {
|
|
744
|
+
position: sticky;
|
|
745
|
+
top: 0;
|
|
746
|
+
z-index: 20;
|
|
747
|
+
background: linear-gradient(to bottom right, #ffffff 0%, #fafafa 100%);
|
|
748
|
+
border-bottom: 1px solid #e2e8f0;
|
|
749
|
+
padding: 24px 24px 16px;
|
|
750
|
+
}
|
|
751
|
+
.sharded-env-title-row {
|
|
752
|
+
display: flex;
|
|
753
|
+
justify-content: space-between;
|
|
754
|
+
align-items: center;
|
|
755
|
+
}
|
|
756
|
+
.sharded-env-title {
|
|
757
|
+
display: flex;
|
|
758
|
+
align-items: center;
|
|
759
|
+
font-size: 18px;
|
|
760
|
+
font-weight: 600;
|
|
761
|
+
color: #0f172a;
|
|
762
|
+
}
|
|
763
|
+
.sharded-env-title svg {
|
|
764
|
+
width: 18px;
|
|
765
|
+
height: 18px;
|
|
766
|
+
margin-right: 8px;
|
|
767
|
+
stroke: currentColor;
|
|
768
|
+
fill: none;
|
|
769
|
+
}
|
|
770
|
+
.sharded-env-subtitle {
|
|
771
|
+
font-size: 13px;
|
|
772
|
+
color: #64748b;
|
|
773
|
+
margin-top: 4px;
|
|
774
|
+
}
|
|
775
|
+
.sharded-environments-container {
|
|
776
|
+
max-height: 520px;
|
|
777
|
+
overflow-y: auto;
|
|
778
|
+
overflow-x: hidden;
|
|
779
|
+
padding: 16px;
|
|
780
|
+
}
|
|
781
|
+
.sharded-environments-container::-webkit-scrollbar {
|
|
782
|
+
width: 8px;
|
|
783
|
+
}
|
|
784
|
+
.sharded-environments-container::-webkit-scrollbar-track {
|
|
785
|
+
background: #f1f1f1;
|
|
786
|
+
border-radius: 4px;
|
|
787
|
+
}
|
|
788
|
+
.sharded-environments-container::-webkit-scrollbar-thumb {
|
|
789
|
+
background: #cbd5e0;
|
|
790
|
+
border-radius: 4px;
|
|
791
|
+
}
|
|
792
|
+
.sharded-environments-container::-webkit-scrollbar-thumb:hover {
|
|
793
|
+
background: #a0aec0;
|
|
794
|
+
}
|
|
795
|
+
.sharded-environments-wrapper {
|
|
796
|
+
display: grid;
|
|
797
|
+
grid-template-columns: repeat(auto-fit, minmax(600px, 1fr));
|
|
798
|
+
gap: 24px;
|
|
799
|
+
}
|
|
800
|
+
@media (max-width: 768px) {
|
|
801
|
+
.sharded-environments-wrapper {
|
|
802
|
+
grid-template-columns: 1fr;
|
|
803
|
+
}
|
|
804
|
+
}
|
|
805
|
+
.env-card-wrapper {
|
|
806
|
+
position: relative;
|
|
807
|
+
}
|
|
808
|
+
.env-card-badge {
|
|
809
|
+
position: absolute;
|
|
810
|
+
top: -10px;
|
|
811
|
+
right: 16px;
|
|
812
|
+
background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
|
|
813
|
+
color: white;
|
|
814
|
+
padding: 6px 14px;
|
|
815
|
+
border-radius: 20px;
|
|
816
|
+
font-size: 0.75em;
|
|
817
|
+
font-weight: 700;
|
|
818
|
+
text-transform: uppercase;
|
|
819
|
+
letter-spacing: 0.5px;
|
|
820
|
+
z-index: 10;
|
|
821
|
+
box-shadow: 0 4px 6px -1px rgba(99, 102, 241, 0.3);
|
|
822
|
+
}
|
|
823
|
+
</style>
|
|
824
|
+
`;
|
|
825
|
+
}
|
|
826
|
+
|
|
827
|
+
return generateEnvironmentDashboard(environmentData);
|
|
828
|
+
}
|
|
699
829
|
|
|
700
|
-
|
|
830
|
+
function generateEnvironmentDashboard(environment, hideHeader = false) {
|
|
831
|
+
const cpuInfo = `model: ${environment.cpu.model}, cores: ${environment.cpu.cores}`;
|
|
832
|
+
const osInfo = environment.os || "N/A";
|
|
833
|
+
const nodeInfo = environment.node || "N/A";
|
|
834
|
+
const v8Info = environment.v8 || "N/A";
|
|
835
|
+
const cwdInfo = environment.cwd || "N/A";
|
|
836
|
+
const formattedMemory = environment.memory || "N/A";
|
|
701
837
|
const runContext = process.env.CI ? "CI" : "Local Test";
|
|
702
838
|
|
|
703
839
|
return `
|
|
704
|
-
<div class="
|
|
840
|
+
<div class="env-modern-card${hideHeader ? " no-header" : ""}">
|
|
705
841
|
<style>
|
|
842
|
+
.env-modern-card {
|
|
843
|
+
background: linear-gradient(to bottom right, #ffffff 0%, #fafafa 100%);
|
|
844
|
+
border: 0;
|
|
845
|
+
border-radius: 12px;
|
|
846
|
+
box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
|
|
847
|
+
margin-top: 24px;
|
|
848
|
+
transition: all 0.3s ease;
|
|
849
|
+
font-family: var(--font-family);
|
|
850
|
+
overflow: hidden;
|
|
851
|
+
}
|
|
852
|
+
.env-modern-card:hover {
|
|
853
|
+
box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
|
|
854
|
+
}
|
|
855
|
+
.env-modern-card {
|
|
856
|
+
margin-bottom: 0;
|
|
857
|
+
}
|
|
858
|
+
|
|
706
859
|
.environment-dashboard-wrapper *,
|
|
707
860
|
.environment-dashboard-wrapper *::before,
|
|
708
861
|
.environment-dashboard-wrapper *::after {
|
|
@@ -726,279 +879,269 @@ function generateEnvironmentDashboard(environment) {
|
|
|
726
879
|
transform: translateZ(0);
|
|
727
880
|
}
|
|
728
881
|
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
}
|
|
882
|
+
.env-card-header {
|
|
883
|
+
display: flex;
|
|
884
|
+
flex-direction: column;
|
|
885
|
+
padding: 24px 24px 12px;
|
|
734
886
|
}
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
padding: 24px;
|
|
738
|
-
}
|
|
887
|
+
.env-modern-card.no-header .env-card-header {
|
|
888
|
+
display: none;
|
|
739
889
|
}
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
grid-column: 1 / -1;
|
|
743
|
-
margin-bottom: 24px;
|
|
890
|
+
.env-modern-card.no-header {
|
|
891
|
+
margin-top: 0;
|
|
744
892
|
}
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
font-size: 2em;
|
|
748
|
-
font-weight: 900;
|
|
749
|
-
color: #0f172a;
|
|
750
|
-
letter-spacing: -0.02em;
|
|
751
|
-
margin: 0 0 8px 0;
|
|
893
|
+
.env-modern-card.no-header .env-card-content {
|
|
894
|
+
padding-top: 24px;
|
|
752
895
|
}
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
margin: 0;
|
|
758
|
-
font-weight: 400;
|
|
896
|
+
.env-card-title-row {
|
|
897
|
+
display: flex;
|
|
898
|
+
justify-content: space-between;
|
|
899
|
+
align-items: center;
|
|
759
900
|
}
|
|
760
|
-
|
|
761
|
-
.env-card {
|
|
762
|
-
background: white;
|
|
763
|
-
border: none;
|
|
764
|
-
border-left: 4px solid #e2e8f0;
|
|
765
|
-
padding: 28px;
|
|
901
|
+
.env-card-title {
|
|
766
902
|
display: flex;
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
903
|
+
align-items: center;
|
|
904
|
+
font-size: 16px;
|
|
905
|
+
font-weight: 600;
|
|
906
|
+
color: #0f172a;
|
|
907
|
+
transition: color 0.3s;
|
|
771
908
|
}
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
border-left-color: var(--primary-color);
|
|
775
|
-
background: #fafbfc;
|
|
909
|
+
.env-modern-card:hover .env-card-title {
|
|
910
|
+
color: #6366f1;
|
|
776
911
|
}
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
912
|
+
.env-card-title svg {
|
|
913
|
+
width: 16px;
|
|
914
|
+
height: 16px;
|
|
915
|
+
margin-right: 8px;
|
|
916
|
+
stroke: currentColor;
|
|
917
|
+
fill: none;
|
|
918
|
+
}
|
|
919
|
+
.env-card-subtitle {
|
|
920
|
+
font-size: 12px;
|
|
921
|
+
color: #64748b;
|
|
922
|
+
margin-top: 4px;
|
|
923
|
+
}
|
|
924
|
+
.env-icon-badge {
|
|
925
|
+
width: 36px;
|
|
926
|
+
height: 36px;
|
|
927
|
+
border-radius: 50%;
|
|
928
|
+
background: linear-gradient(to bottom right, rgba(99, 102, 241, 0.1), rgba(99, 102, 241, 0.05));
|
|
782
929
|
display: flex;
|
|
783
930
|
align-items: center;
|
|
784
|
-
|
|
785
|
-
text-transform: uppercase;
|
|
786
|
-
letter-spacing: 0.5px;
|
|
931
|
+
justify-content: center;
|
|
787
932
|
}
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
fill:
|
|
933
|
+
.env-icon-badge svg {
|
|
934
|
+
width: 16px;
|
|
935
|
+
height: 16px;
|
|
936
|
+
stroke: #6366f1;
|
|
937
|
+
fill: none;
|
|
793
938
|
}
|
|
794
|
-
|
|
795
939
|
.env-card-content {
|
|
796
|
-
|
|
797
|
-
flex-direction: column;
|
|
798
|
-
gap: 16px;
|
|
799
|
-
}
|
|
800
|
-
|
|
801
|
-
.env-detail-row {
|
|
802
|
-
display: flex;
|
|
803
|
-
justify-content: space-between;
|
|
804
|
-
align-items: flex-start;
|
|
805
|
-
gap: 16px;
|
|
806
|
-
font-size: 1em;
|
|
807
|
-
padding: 8px 0;
|
|
940
|
+
padding: 0 24px 24px;
|
|
808
941
|
}
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
font-size: 0.9em;
|
|
814
|
-
text-transform: uppercase;
|
|
815
|
-
letter-spacing: 0.3px;
|
|
816
|
-
flex-shrink: 0;
|
|
942
|
+
.env-items-grid {
|
|
943
|
+
display: grid;
|
|
944
|
+
grid-template-columns: repeat(2, 1fr);
|
|
945
|
+
gap: 10px;
|
|
817
946
|
}
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
font-size: 0.95em;
|
|
823
|
-
text-align: right;
|
|
824
|
-
word-break: break-word;
|
|
825
|
-
margin-left: auto;
|
|
947
|
+
@media (min-width: 768px) {
|
|
948
|
+
.env-items-grid {
|
|
949
|
+
grid-template-columns: repeat(4, 1fr);
|
|
950
|
+
}
|
|
826
951
|
}
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
padding:
|
|
832
|
-
border-radius:
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
text-transform: uppercase;
|
|
836
|
-
letter-spacing: 0.5px;
|
|
952
|
+
.env-item {
|
|
953
|
+
display: flex;
|
|
954
|
+
align-items: flex-start;
|
|
955
|
+
gap: 8px;
|
|
956
|
+
padding: 8px;
|
|
957
|
+
border-radius: 8px;
|
|
958
|
+
transition: background-color 0.2s;
|
|
959
|
+
min-height: 48px;
|
|
837
960
|
}
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
background-color: #ede9fe;
|
|
841
|
-
color: #6366f1;
|
|
961
|
+
.env-item:hover {
|
|
962
|
+
background-color: rgba(100, 116, 139, 0.05);
|
|
842
963
|
}
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
background-color: #d1fae5;
|
|
846
|
-
color: #10b981;
|
|
964
|
+
.env-item-icon {
|
|
965
|
+
flex-shrink: 0;
|
|
847
966
|
}
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
967
|
+
.env-item-icon svg {
|
|
968
|
+
width: 16px;
|
|
969
|
+
height: 16px;
|
|
970
|
+
stroke: #6366f1;
|
|
971
|
+
fill: none;
|
|
852
972
|
}
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
align-items: center;
|
|
857
|
-
gap: 6px;
|
|
973
|
+
.env-item-content {
|
|
974
|
+
flex-grow: 1;
|
|
975
|
+
min-width: 0;
|
|
858
976
|
}
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
977
|
+
.env-item-label {
|
|
978
|
+
font-size: 12px;
|
|
979
|
+
font-weight: 500;
|
|
980
|
+
color: #64748b;
|
|
981
|
+
white-space: nowrap;
|
|
982
|
+
overflow: hidden;
|
|
983
|
+
text-overflow: ellipsis;
|
|
866
984
|
}
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
985
|
+
.env-item-value {
|
|
986
|
+
font-size: 12px;
|
|
987
|
+
font-weight: 600;
|
|
988
|
+
color: #0f172a;
|
|
989
|
+
word-wrap: break-word;
|
|
990
|
+
overflow-wrap: break-word;
|
|
991
|
+
line-height: 1.4;
|
|
872
992
|
}
|
|
873
993
|
</style>
|
|
874
994
|
|
|
875
|
-
<div class="env-
|
|
876
|
-
<div>
|
|
877
|
-
<
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
<div class="env-card-content">
|
|
889
|
-
<div class="env-detail-row">
|
|
890
|
-
<span class="env-detail-label">CPU Model</span>
|
|
891
|
-
<span class="env-detail-value">${environment.cpu.model}</span>
|
|
892
|
-
</div>
|
|
893
|
-
<div class="env-detail-row">
|
|
894
|
-
<span class="env-detail-label">CPU Cores</span>
|
|
895
|
-
<span class="env-detail-value">
|
|
896
|
-
<div class="env-cpu-cores">
|
|
897
|
-
<span>${environment.cpu.cores || "N/A"} core${environment.cpu.cores !== 1 ? "s" : ""}</span>
|
|
898
|
-
</div>
|
|
899
|
-
</span>
|
|
995
|
+
<div class="env-card-header">
|
|
996
|
+
<div class="env-card-title-row">
|
|
997
|
+
<div>
|
|
998
|
+
<div class="env-card-title">
|
|
999
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1000
|
+
<rect width="20" height="8" x="2" y="2" rx="2" ry="2"></rect>
|
|
1001
|
+
<rect width="20" height="8" x="2" y="14" rx="2" ry="2"></rect>
|
|
1002
|
+
<line x1="6" x2="6.01" y1="6" y2="6"></line>
|
|
1003
|
+
<line x1="6" x2="6.01" y1="18" y2="18"></line>
|
|
1004
|
+
</svg>
|
|
1005
|
+
System Information
|
|
1006
|
+
</div>
|
|
1007
|
+
<div class="env-card-subtitle">Test execution environment details</div>
|
|
900
1008
|
</div>
|
|
901
|
-
<div class="env-
|
|
902
|
-
<
|
|
903
|
-
|
|
1009
|
+
<div class="env-icon-badge">
|
|
1010
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1011
|
+
<path d="M20 16V7a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v9m16 0H4m16 0 1.28 2.55a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45L4 16"></path>
|
|
1012
|
+
</svg>
|
|
904
1013
|
</div>
|
|
905
1014
|
</div>
|
|
906
1015
|
</div>
|
|
907
1016
|
|
|
908
|
-
<div class="env-card">
|
|
909
|
-
<div class="env-
|
|
910
|
-
<
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
<
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
}</span>
|
|
921
|
-
</div>
|
|
922
|
-
<div class="env-detail-row">
|
|
923
|
-
<span class="env-detail-label">OS Version</span>
|
|
924
|
-
<span class="env-detail-value">${
|
|
925
|
-
environment.os.split(" ")[1] || "N/A"
|
|
926
|
-
}</span>
|
|
927
|
-
</div>
|
|
928
|
-
<div class="env-detail-row">
|
|
929
|
-
<span class="env-detail-label">Hostname</span>
|
|
930
|
-
<span class="env-detail-value" title="${environment.host}">${
|
|
931
|
-
environment.host
|
|
932
|
-
}</span>
|
|
1017
|
+
<div class="env-card-content">
|
|
1018
|
+
<div class="env-items-grid">
|
|
1019
|
+
<div class="env-item">
|
|
1020
|
+
<div class="env-item-icon">
|
|
1021
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1022
|
+
<path d="M20 16V7a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v9m16 0H4m16 0 1.28 2.55a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45L4 16"></path>
|
|
1023
|
+
</svg>
|
|
1024
|
+
</div>
|
|
1025
|
+
<div class="env-item-content">
|
|
1026
|
+
<p class="env-item-label">Host</p>
|
|
1027
|
+
<div class="env-item-value" title="${environment.host}">${environment.host}</div>
|
|
1028
|
+
</div>
|
|
933
1029
|
</div>
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
<span class="env-detail-value">${environment.node}</span>
|
|
1030
|
+
|
|
1031
|
+
<div class="env-item">
|
|
1032
|
+
<div class="env-item-icon">
|
|
1033
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1034
|
+
<path d="M20 16V7a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v9m16 0H4m16 0 1.28 2.55a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45L4 16"></path>
|
|
1035
|
+
</svg>
|
|
1036
|
+
</div>
|
|
1037
|
+
<div class="env-item-content">
|
|
1038
|
+
<p class="env-item-label">Os</p>
|
|
1039
|
+
<div class="env-item-value" title="${environment.os}">${environment.os}</div>
|
|
1040
|
+
</div>
|
|
946
1041
|
</div>
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
<
|
|
1042
|
+
|
|
1043
|
+
<div class="env-item">
|
|
1044
|
+
<div class="env-item-icon">
|
|
1045
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1046
|
+
<rect width="16" height="16" x="4" y="4" rx="2"></rect>
|
|
1047
|
+
<rect width="6" height="6" x="9" y="9" rx="1"></rect>
|
|
1048
|
+
<path d="M15 2v2"></path>
|
|
1049
|
+
<path d="M15 20v2"></path>
|
|
1050
|
+
<path d="M2 15h2"></path>
|
|
1051
|
+
<path d="M2 9h2"></path>
|
|
1052
|
+
<path d="M20 15h2"></path>
|
|
1053
|
+
<path d="M20 9h2"></path>
|
|
1054
|
+
<path d="M9 2v2"></path>
|
|
1055
|
+
<path d="M9 20v2"></path>
|
|
1056
|
+
</svg>
|
|
1057
|
+
</div>
|
|
1058
|
+
<div class="env-item-content">
|
|
1059
|
+
<p class="env-item-label">Cpu</p>
|
|
1060
|
+
<div class="env-item-value" title='${JSON.stringify(environment.cpu)}'>${cpuInfo}</div>
|
|
1061
|
+
</div>
|
|
950
1062
|
</div>
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
<
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
1063
|
+
|
|
1064
|
+
<div class="env-item">
|
|
1065
|
+
<div class="env-item-icon">
|
|
1066
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1067
|
+
<path d="M6 19v-3"></path>
|
|
1068
|
+
<path d="M10 19v-3"></path>
|
|
1069
|
+
<path d="M14 19v-3"></path>
|
|
1070
|
+
<path d="M18 19v-3"></path>
|
|
1071
|
+
<path d="M8 11V9"></path>
|
|
1072
|
+
<path d="M16 11V9"></path>
|
|
1073
|
+
<path d="M12 11V9"></path>
|
|
1074
|
+
<path d="M2 15h20"></path>
|
|
1075
|
+
<path d="M2 7a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v1.1a2 2 0 0 0 0 3.837V17a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2v-5.1a2 2 0 0 0 0-3.837Z"></path>
|
|
1076
|
+
</svg>
|
|
1077
|
+
</div>
|
|
1078
|
+
<div class="env-item-content">
|
|
1079
|
+
<p class="env-item-label">Memory</p>
|
|
1080
|
+
<div class="env-item-value" title="${environment.memory}">${environment.memory}</div>
|
|
1081
|
+
</div>
|
|
958
1082
|
</div>
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
? "ARM-based"
|
|
984
|
-
: "x86/Other"
|
|
985
|
-
}
|
|
986
|
-
</span>
|
|
987
|
-
</span>
|
|
1083
|
+
|
|
1084
|
+
<div class="env-item">
|
|
1085
|
+
<div class="env-item-icon">
|
|
1086
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1087
|
+
<path d="M12 20a8 8 0 1 0 0-16 8 8 0 0 0 0 16Z"></path>
|
|
1088
|
+
<path d="M12 14a2 2 0 1 0 0-4 2 2 0 0 0 0 4Z"></path>
|
|
1089
|
+
<path d="M12 2v2"></path>
|
|
1090
|
+
<path d="M12 22v-2"></path>
|
|
1091
|
+
<path d="m17 20.66-1-1.73"></path>
|
|
1092
|
+
<path d="M11 10.27 7 3.34"></path>
|
|
1093
|
+
<path d="m20.66 17-1.73-1"></path>
|
|
1094
|
+
<path d="m3.34 7 1.73 1"></path>
|
|
1095
|
+
<path d="M14 12h8"></path>
|
|
1096
|
+
<path d="M2 12h2"></path>
|
|
1097
|
+
<path d="m20.66 7-1.73 1"></path>
|
|
1098
|
+
<path d="m3.34 17 1.73-1"></path>
|
|
1099
|
+
<path d="m17 3.34-1 1.73"></path>
|
|
1100
|
+
<path d="m11 13.73-4 6.93"></path>
|
|
1101
|
+
</svg>
|
|
1102
|
+
</div>
|
|
1103
|
+
<div class="env-item-content">
|
|
1104
|
+
<p class="env-item-label">Node</p>
|
|
1105
|
+
<div class="env-item-value" title="${environment.node}">${environment.node}</div>
|
|
1106
|
+
</div>
|
|
988
1107
|
</div>
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
<
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
1108
|
+
|
|
1109
|
+
<div class="env-item">
|
|
1110
|
+
<div class="env-item-icon">
|
|
1111
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1112
|
+
<path d="M12 20a8 8 0 1 0 0-16 8 8 0 0 0 0 16Z"></path>
|
|
1113
|
+
<path d="M12 14a2 2 0 1 0 0-4 2 2 0 0 0 0 4Z"></path>
|
|
1114
|
+
<path d="M12 2v2"></path>
|
|
1115
|
+
<path d="M12 22v-2"></path>
|
|
1116
|
+
<path d="m17 20.66-1-1.73"></path>
|
|
1117
|
+
<path d="M11 10.27 7 3.34"></path>
|
|
1118
|
+
<path d="m20.66 17-1.73-1"></path>
|
|
1119
|
+
<path d="m3.34 7 1.73 1"></path>
|
|
1120
|
+
<path d="M14 12h8"></path>
|
|
1121
|
+
<path d="M2 12h2"></path>
|
|
1122
|
+
<path d="m20.66 7-1.73 1"></path>
|
|
1123
|
+
<path d="m3.34 17 1.73-1"></path>
|
|
1124
|
+
<path d="m17 3.34-1 1.73"></path>
|
|
1125
|
+
<path d="m11 13.73-4 6.93"></path>
|
|
1126
|
+
</svg>
|
|
1127
|
+
</div>
|
|
1128
|
+
<div class="env-item-content">
|
|
1129
|
+
<p class="env-item-label">V8</p>
|
|
1130
|
+
<div class="env-item-value" title="${environment.v8}">${environment.v8}</div>
|
|
1131
|
+
</div>
|
|
998
1132
|
</div>
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
<
|
|
1133
|
+
|
|
1134
|
+
<div class="env-item">
|
|
1135
|
+
<div class="env-item-icon">
|
|
1136
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
1137
|
+
<path d="m3 9 9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z"></path>
|
|
1138
|
+
<polyline points="9 22 9 12 15 12 15 22"></polyline>
|
|
1139
|
+
</svg>
|
|
1140
|
+
</div>
|
|
1141
|
+
<div class="env-item-content">
|
|
1142
|
+
<p class="env-item-label">Working Dir</p>
|
|
1143
|
+
<div class="env-item-value" title="${environment.cwd}">${environment.cwd.length > 30 ? "..." + environment.cwd.slice(-27) : environment.cwd}</div>
|
|
1144
|
+
</div>
|
|
1002
1145
|
</div>
|
|
1003
1146
|
</div>
|
|
1004
1147
|
</div>
|
|
@@ -2145,6 +2288,13 @@ function generateHTML(reportData, trendData = null) {
|
|
|
2145
2288
|
)}</div>`
|
|
2146
2289
|
: ""
|
|
2147
2290
|
}
|
|
2291
|
+
${
|
|
2292
|
+
step.codeSnippet
|
|
2293
|
+
? `<div class="code-snippet-section"><pre class="code-snippet">${sanitizeHTML(
|
|
2294
|
+
step.codeSnippet,
|
|
2295
|
+
)}</pre></div>`
|
|
2296
|
+
: ""
|
|
2297
|
+
}
|
|
2148
2298
|
${
|
|
2149
2299
|
step.errorMessage
|
|
2150
2300
|
? `<div class="test-error-summary">
|
|
@@ -3207,8 +3357,9 @@ function generateHTML(reportData, trendData = null) {
|
|
|
3207
3357
|
border: none;
|
|
3208
3358
|
border-left: 4px solid #e2e8f0;
|
|
3209
3359
|
padding: 24px;
|
|
3210
|
-
background:
|
|
3360
|
+
background: cornsilk;
|
|
3211
3361
|
transition: all 0.15s ease;
|
|
3362
|
+
border-radius: 10px;
|
|
3212
3363
|
}
|
|
3213
3364
|
.suite-card:hover {
|
|
3214
3365
|
background: #fafbfc;
|
|
@@ -3518,6 +3669,8 @@ function generateHTML(reportData, trendData = null) {
|
|
|
3518
3669
|
.step-duration { color: var(--dark-gray-color); font-size: 0.9em; }
|
|
3519
3670
|
.step-details { display: none; padding: 14px; margin-top: 8px; background: #fdfdfd; border-radius: 6px; font-size: 0.95em; border: 1px solid var(--light-gray-color); }
|
|
3520
3671
|
.step-info { margin-bottom: 8px; }
|
|
3672
|
+
.code-snippet-section { margin: 12px 0; }
|
|
3673
|
+
.code-snippet { background-color: #f8f9fa; border: 1px solid #e1e4e8; border-radius: 6px; padding: 12px; font-family: 'Consolas', 'Monaco', 'Courier New', monospace; font-size: 0.9em; line-height: 1.5; overflow-x: auto; color: #24292e; margin: 0; white-space: pre; }
|
|
3521
3674
|
.test-error-summary { color: var(--danger-color); margin-top: 12px; padding: 14px; background: rgba(244,67,54,0.05); border-radius: 4px; font-size: 0.95em; border-left: 3px solid var(--danger-color); }
|
|
3522
3675
|
.test-error-summary pre.stack-trace { margin-top: 10px; padding: 12px; background-color: rgba(0,0,0,0.03); border-radius: 4px; font-size:0.9em; max-height: 280px; overflow-y: auto; white-space: pre-wrap; word-break: break-all; }
|
|
3523
3676
|
.step-hook { background-color: rgba(33,150,243,0.04); border-left: 3px solid var(--info-color) !important; }
|
|
@@ -4094,12 +4247,7 @@ function generateHTML(reportData, trendData = null) {
|
|
|
4094
4247
|
400,
|
|
4095
4248
|
390,
|
|
4096
4249
|
)}
|
|
4097
|
-
${
|
|
4098
|
-
runSummary.environment &&
|
|
4099
|
-
Object.keys(runSummary.environment).length > 0
|
|
4100
|
-
? generateEnvironmentDashboard(runSummary.environment)
|
|
4101
|
-
: '<div class="no-data">Environment data not available.</div>'
|
|
4102
|
-
}
|
|
4250
|
+
${generateEnvironmentSection(runSummary.environment)}
|
|
4103
4251
|
</div>
|
|
4104
4252
|
|
|
4105
4253
|
<div class="dashboard-column">
|
|
@@ -4675,6 +4823,8 @@ async function runScript(scriptPath, args = []) {
|
|
|
4675
4823
|
});
|
|
4676
4824
|
}
|
|
4677
4825
|
async function main() {
|
|
4826
|
+
await animate();
|
|
4827
|
+
|
|
4678
4828
|
const __filename = fileURLToPath(import.meta.url);
|
|
4679
4829
|
const __dirname = path.dirname(__filename);
|
|
4680
4830
|
|
|
@@ -4866,7 +5016,7 @@ async function main() {
|
|
|
4866
5016
|
await fs.writeFile(reportHtmlPath, htmlContent, "utf-8");
|
|
4867
5017
|
console.log(
|
|
4868
5018
|
chalk.green.bold(
|
|
4869
|
-
|
|
5019
|
+
`Pulse report generated successfully at: ${reportHtmlPath}`,
|
|
4870
5020
|
),
|
|
4871
5021
|
);
|
|
4872
5022
|
console.log(chalk.gray(`(You can open this file in your browser)`));
|