Skip to content

Commit

Permalink
v2
Browse files Browse the repository at this point in the history
  • Loading branch information
Oleg Nechiporenko authored and Oleg Nechiporenko committed Feb 26, 2025
1 parent 666be83 commit 15b5881
Show file tree
Hide file tree
Showing 10 changed files with 2,264 additions and 655 deletions.
64 changes: 64 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
name: CI

on:
push:
branches:
- main
- master
pull_request: {}

concurrency:
group: ci-${{ github.head_ref || github.ref }}
cancel-in-progress: true

jobs:
test:
name: "Tests"
runs-on: ubuntu-latest
timeout-minutes: 10

steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v4
with:
version: 9
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 18
cache: pnpm
- name: Install Dependencies
run: pnpm install --frozen-lockfile
- name: Lint
run: pnpm lint
- name: Run Tests
run: pnpm test

tries:
name: "Tries"
runs-on: ubuntu-latest
timeout-minutes: 10

strategy:
matrix:
node: [16, 18, 20, 22]
chai: [4, 5]

steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v4
with:
version: 9
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
cache: pnpm
- name: Install Dependencies
run: |
pnpm install --frozen-lockfile
pnpm i -D chai@${{ matrix.chai }}
- name: Lint
run: pnpm lint
- name: Run Tests
run: pnpm test
26 changes: 0 additions & 26 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,29 +1,3 @@
# Logs
logs
*.log

# Runtime data
pids
*.pid
*.seed

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# node-waf configuration
.lock-wscript

# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release

# Dependency directory
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git
node_modules

.idea
11 changes: 0 additions & 11 deletions .travis.yml

This file was deleted.

16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ chai.use(require('chai-string'));
## Assertions

* startsWith/startWith
* startsWithIgnoreCase/startWithIgnoreCase
* endsWith/endWith
* endsWithIgnoreCase/endWithIgnoreCase
* equalIgnoreCase
* equalIgnoreSpaces
* containIgnoreSpaces
Expand Down Expand Up @@ -53,13 +55,27 @@ expect('abcdef').to.startsWith('abc');
'abcdef'.should.startWith('abc');
```

### startsWithIgnoreCase/startWithIgnoreCase
```javascript
assert.startsWithIgnoreCase('aBcdef', 'abC');
expect('abCdef').to.startsWithIgnoreCase('Abc');
'Abcdef'.should.startWithIgnoreCase('aBc');
```

### endsWith/endWith
```javascript
assert.endsWith('abcdef', 'def');
expect('abcdef').to.endsWith('def');
'abcdef'.should.endWith('def');
```

### endsWithIgnoreCase/endWithIgnoreCase
```javascript
assert.endsWithIgnoreCase('abcdEf', 'deF');
expect('abcDef').to.endsWithIgnoreCase('dEf');
'abcdeF'.should.endWithIgnoreCase('Def');
```

### equalIgnoreCase
```javascript
assert.equalIgnoreCase('abcdef', 'AbCdEf');
Expand Down
Loading

0 comments on commit 15b5881

Please sign in to comment.