Skip to content

Commit

Permalink
fix: Исправлено склонение слов при выводе продолжительности теста
Browse files Browse the repository at this point in the history
  • Loading branch information
Nitive authored and qtm committed Jan 28, 2022
1 parent e1f5ba1 commit fc8ed4a
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
1 change: 1 addition & 0 deletions modules/tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
"lodash": "^4.17.21",
"mime-types": "^2.1.32",
"package-json": "^6.5.0",
"pluralize": "^8.0.0",
"prettier": "2.2.1",
"readline-sync": "^1.4.10",
"validate-npm-package-name": "^3.0.0",
Expand Down
7 changes: 4 additions & 3 deletions modules/tools/upload-allure-report.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ const path = require('path')
const klaw = require('klaw')
const crypto = require('crypto')
const chalk = require('chalk')
const pluralize = require('pluralize')
const allure = require('allure-commandline')
const mime = require('mime-types')
const { S3 } = require('@aws-sdk/client-s3')
Expand Down Expand Up @@ -144,9 +145,9 @@ function formatDuration(ms) {
const seconds = totalSeconds - totalMinutes * 60

return [
hours && `${hours} hours`,
minutes && `${minutes} minutes`,
seconds && `${seconds} seconds`,
hours && pluralize('hour', hours),
minutes && pluralize('minute', minutes),
seconds && pluralize('second', seconds),
]
.filter(Boolean)
.join(' ')
Expand Down
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -9124,6 +9124,11 @@ playwright@^1.12.3:
ws "^7.4.6"
yazl "^2.5.1"

pluralize@^8.0.0:
version "8.0.0"
resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-8.0.0.tgz#1a6fa16a38d12a1901e0320fa017051c539ce3b1"
integrity sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA==

pngjs@^5.0.0:
version "5.0.0"
resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-5.0.0.tgz#e79dd2b215767fd9c04561c01236df960bce7fbb"
Expand Down

0 comments on commit fc8ed4a

Please sign in to comment.