Skip to content

Commit

Permalink
Merge pull request #77 from RahulARanger/nodejs-reporters
Browse files Browse the repository at this point in the history
revert: module alias imports in handshake nodejs-reporters
  • Loading branch information
RahulARanger authored Mar 14, 2024
2 parents 1852306 + a246ced commit 8bc77c4
Show file tree
Hide file tree
Showing 47 changed files with 187 additions and 207 deletions.
2 changes: 1 addition & 1 deletion handshake-nodejs-reporters/apps/docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,6 @@
"react-dom": "^18.2.0",
"typescript": "^5.3.3",
"handshake-utils": "0.5.0",
"handshake-dashboard": "0.5.0"
"handshake-dashboard": "0.5.1"
}
}
1 change: 1 addition & 0 deletions handshake-nodejs-reporters/apps/test-export/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"test": "echo \"Error: no test specified\" && exit 1",
"wdio": "wdio run ./wdio.conf.ts",
"export": "cd ../../ && npx handshake export ../TestResults --out ../TestReports",
"run-sanity": "cd ../../ && npm run sanity",
"verify-sanity": "npx cross-env TYPE=SANITY wdio run ./wdio.conf.ts --cucumberOpts.tagExpression=\"@sanity\"",
"dev-sanity": "npx cross-env PORT=8000 wdio run ./wdio.conf.ts --cucumberOpts.tagExpression=\"@sanity\""
},
Expand Down
34 changes: 17 additions & 17 deletions handshake-nodejs-reporters/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# handshake

## 0.5.1

### Patch Changes

- bb38cb3: revert: module alias path and feat: use the relative paths from the src

## 0.5.0

### Minor Changes
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Exporting Next-JS app was bit confusing for me at first, have spent a lot of tim

- when the command line has this particular directory as its root then it should be able to use the command `npm run export`
- after running the export command, it should avoid linting next-js as it would be taken care before deploying the changes.
- First it generates the `antd.min.css` in the `src/styles` directory. the above file is not distributed. `scripts/genAntdCSS.ts` generates the file
- First it generates the `antd.min.css` in the `styles` directory. the above file is not distributed. `scripts/genAntdCSS.ts` generates the file
- and then it would generate the html files inside the requested output directory through `next build` command.

### Changes made
Expand Down Expand Up @@ -62,4 +62,4 @@ Check out our [Next.js deployment documentation](https://nextjs.org/docs/deploym
## Note

<a target="_blank" href="https://icons8.com/icon/gXoJoyTtYXFg/windows-10">Windows</a> icon by <a target="_blank" href="https://icons8.com">Icons8</a>
<a href="https://www.flaticon.com/free-icons/linux" title="linux icons">Linux icons created by Freepik - Flaticon</a>
<a href="https://www.flaticon.com/free-icons/linux" title="linux icons">Linux icons created by Freepik - Flaticon</a>
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
const { PHASE_DEVELOPMENT_SERVER } = require("next/constants");
const withBundleAnalyzer = require('@next/bundle-analyzer')({
enabled: process.env.ANALYZE === 'true',
})

module.exports = (phase, { defaultConfig }) => {
const is_dev = phase === PHASE_DEVELOPMENT_SERVER;

let withBundleAnalyzer;

if (process.env.ANALYZE === 'true')
withBundleAnalyzer = require('@next/bundle-analyzer')({
enabled: true,
})

/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: true,
Expand All @@ -23,5 +27,6 @@ module.exports = (phase, { defaultConfig }) => {
distDir: process.env.EXPORT_DIR ?? "dist",
typescript: { ignoreBuildErrors: !is_dev }
}
return withBundleAnalyzer(nextConfig)

return withBundleAnalyzer ? withBundleAnalyzer(nextConfig) : nextConfig;
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "handshake-dashboard",
"version": "0.5.0",
"version": "0.5.1",
"license": "MIT",
"scripts": {
"dev": "next dev",
Expand All @@ -20,7 +20,7 @@
"@tsconfig/node18": "^18.2.2",
"@types/echarts": "^4.9.22",
"@types/node": "20.11.27",
"@types/react": "^18.2.65",
"@types/react": "^18.2.66",
"@types/react-dom": "18.2.22",
"@uiw/react-markdown-preview": "^5.0.10",
"ansi-to-html": "^0.7.2",
Expand All @@ -45,7 +45,7 @@
"@ant-design/static-style-extract": "~1.0.2",
"@next/eslint-plugin-next": "^14.1.3",
"@types/react-highlight-words": "^0.16.7",
"@typescript-eslint/eslint-plugin": "^7.1.1",
"@typescript-eslint/eslint-plugin": "^7.2.0",
"@typescript-eslint/parser": "^7.2.0",
"eslint": "^8.57.0",
"eslint-config-prettier": "^9.1.0",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type TestRunRecord from 'src/types/test-run-records';
import type TestRunRecord from 'types/test-run-records';
import React, { type ReactNode } from 'react';
import dayjs from 'dayjs';
import DayJSUtc from 'dayjs/plugin/utc';
Expand Down Expand Up @@ -43,8 +43,8 @@ import {
serif,
toolTipFormats,
} from './constants';
import { dateTimeFormatUsed } from '../utils/Datetime/format';
import type { DetailedTestRecord } from '@/types/parsed-records';
import { dateTimeFormatUsed } from '../datetime/format';
import type { DetailedTestRecord } from 'types/parsed-records';
import type {
GridComponentOption,
MarkLineComponentOption,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,7 @@ import { LabelLayout, UniversalTransition } from 'echarts/features';
// Note that including the CanvasRenderer or SVGRenderer is a required step
import { SVGRenderer } from 'echarts/renderers';
import { standingToColors, toolTipFormats } from './constants';
import type {
ParsedSuiteRecord,
ParsedTestRecord,
} from 'src/types/parsed-records';
import type { ParsedSuiteRecord, ParsedTestRecord } from 'types/parsed-records';
import type {
CallbackDataParams,
TopLevelFormatterParams,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { specNode } from 'src/types/test-run-records';
import type { specNode } from 'types/test-run-records';
import React, { Component, type ReactNode } from 'react';
import ReactECharts from 'echarts-for-react';
import * as echarts from 'echarts/core';
Expand All @@ -24,8 +24,8 @@ import type { ComposeOption } from 'echarts/core';
import { SVGRenderer } from 'echarts/renderers';
import { standingToColors, toolTipFormats } from './constants';
import type { TreemapSeriesOption } from 'echarts/lib/echarts';
import type { StatusContext } from 'src/types/transfer-structure-context';
import type { SuiteDetails } from 'src/types/parsed-records';
import type { StatusContext } from 'types/transfer-structure-context';
import type { SuiteDetails } from 'types/parsed-records';

type composed = ComposeOption<
| TreemapSeriesOption
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import type TestRunRecord from 'src/types/test-run-records';
import type TestRunRecord from 'types/test-run-records';
import React, { useState, type ReactNode } from 'react';
import { parseDetailedTestRun } from '@/components/parse-utils';
import AreaChartForRuns from '@/components/charts/collection-of-runs';
import RenderPassedRate from '@/components/charts/stacked-bar-chart';
import { parseDetailedTestRun } from 'components/parse-utils';
import AreaChartForRuns from 'components/charts/collection-of-runs';
import RenderPassedRate from 'components/charts/stacked-bar-chart';
import crumbs from './test-items';
import { dateFormatUsed } from '@/components/utils/Datetime/format';
import HeaderStyles from '@/styles/header.module.css';
import { dateFormatUsed } from 'components/datetime/format';
import HeaderStyles from 'styles/header.module.css';
import Switch from 'antd/lib/switch';
import List from 'antd/lib/list';
import Space from 'antd/lib/space';
Expand All @@ -27,17 +27,12 @@ import Link from 'antd/lib/typography/Link';
import isBetween from 'dayjs/plugin/isBetween';
import type { RangePickerProps } from 'antd/lib/date-picker';
import Tag from 'antd/lib/tag/index';
import RelativeTo, {
RenderDuration,
} from '@/components/utils/Datetime/relative-time';
import {
RenderFrameworkUsed,
RenderStatus,
} from '@/components/utils/renderers';
import type { DetailedTestRecord } from '@/types/parsed-records';
import RelativeTo, { RenderDuration } from 'components/datetime/relative-time';
import { RenderFrameworkUsed, RenderStatus } from 'components/renderers';
import type { DetailedTestRecord } from 'types/parsed-records';
import { LOCATORS, TEXT } from 'handshake-utils';
import type { TestRecord } from '@/types/test-run-records';
import CardStyles from 'src/styles/card.module.css';
import type { TestRecord } from 'types/test-run-records';
import CardStyles from 'styles/card.module.css';
import Ribbon from 'antd/lib/badge/Ribbon';
import AboutModal from '../about';
dayjs.extend(isBetween);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import GridOfRuns from '@/core/ListOfRuns';
import GridOfRuns from 'components/core/ListOfRuns';
import React, { type ReactNode } from 'react';
import Head from 'next/head';
import { TEXT } from 'handshake-utils';
import type { TestRecord } from '@/types/test-run-records';
import type { TestRecord } from 'types/test-run-records';

export default function AllTestRunsDisplayedHere(properties: {
runs: TestRecord[];
Expand Down
Original file line number Diff line number Diff line change
@@ -1,24 +1,19 @@
import type { Assertion, ErrorRecord } from 'src/types/test-entity-related';
import type { Assertion, ErrorRecord } from 'types/test-entity-related';
import React from 'react';
import Space from 'antd/lib/space';
import Paragraph from 'antd/lib/typography/Paragraph';
import Text from 'antd/lib/typography/Text';
import type { CollapseProps } from 'antd/lib';
import { Collapse, Tag, Tooltip } from 'antd/lib';
import type {
ParsedSuiteRecord,
ParsedTestRecord,
} from 'src/types/parsed-records';
import type { ParsedSuiteRecord, ParsedTestRecord } from 'types/parsed-records';
import { useContext } from 'react';
import Alert from 'antd/lib/alert/Alert';
import Breadcrumb from 'antd/lib/breadcrumb/Breadcrumb';
import { DetailedContext } from '@/types/records-in-detailed';
import GalleryOfImages, {
PlainImage,
} from 'src/components/utils/images-with-thumbnails';
import { DetailedContext } from 'types/records-in-detailed';
import GalleryOfImages, { PlainImage } from 'components/images-with-thumbnails';
import type { Dayjs } from 'dayjs';
import { DurationLayer } from './header';
import Counter from '@/components/utils/counter';
import Counter from 'components/charts/counter';

export default function EntityItem(properties: {
entity: ParsedSuiteRecord | ParsedTestRecord;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ import type { TextProps } from 'antd/lib/typography/Text';
import Button from 'antd/lib/button/button';
import type { Dayjs } from 'dayjs';
import React from 'react';
import { RenderTestItem } from '@/components/utils/renderers';
import type { statusOfEntity } from '@/types/session-records';
import { RenderTestItem } from 'components/renderers';
import type { statusOfEntity } from 'types/session-records';
import EntityItem from './entity-item';
import type {
ParsedSuiteRecord,
ParsedTestRecord,
SuiteDetails,
TestDetails,
} from '@/types/parsed-records';
} from 'types/parsed-records';

export function extractNeighborSuite(
suites: SuiteDetails,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,16 @@ import CaretRightOutlined from '@ant-design/icons/CaretRightOutlined';
import CaretLeftOutlined from '@ant-design/icons/CaretLeftOutlined';
import Space from 'antd/lib/space';
import Button from 'antd/lib/button/button';
import RenderTestType from '@/components/utils/test-status-dot';
import RenderTestType from 'components/test-status-dot';
import Text from 'antd/lib/typography/Text';
import { Badge, Divider, Tooltip } from 'antd/lib';
import { childBadge, parentBadge, retriedBadge } from './constants';
import { ShowContribution } from '@/components/utils/counter';
import { RenderEntityType } from '@/components/utils/renderers';
import { DetailedContext } from '@/types/records-in-detailed';
import type {
ParsedSuiteRecord,
ParsedTestRecord,
} from 'src/types/parsed-records';
import { ShowContribution } from 'components/charts/counter';
import { RenderEntityType } from 'components/renderers';
import { DetailedContext } from 'types/records-in-detailed';
import type { ParsedSuiteRecord, ParsedTestRecord } from 'types/parsed-records';
import { extractNeighborSuite } from './extractors';
import RelativeTo, {
DurationText,
} from '@/components/utils/Datetime/relative-time';
import RelativeTo, { DurationText } from 'components/datetime/relative-time';
import type { Dayjs } from 'dayjs';

export function NavigationButtons(properties: {
Expand Down
Loading

0 comments on commit 8bc77c4

Please sign in to comment.