Skip to content

Commit

Permalink
Merge pull request #839 from XiaoMi/feature/re-dev
Browse files Browse the repository at this point in the history
Feature/re dev
  • Loading branch information
solarjoker authored Dec 25, 2019
2 parents 755a70c + 4d794dd commit 062bd4b
Show file tree
Hide file tree
Showing 5 changed files with 22,681 additions and 11 deletions.
6 changes: 6 additions & 0 deletions README-zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,12 @@ $ npm start

打开 http://localhost:4200

### 单元测试

```
$ npm run jest:coverage
```

#### 添加展示/文档模块

1.`components/index.js` 下添加 `export { default as XXX } from './XXX'`
Expand Down
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,12 @@ $ npm start

Open http://localhost:4200

### Unit Testing

```
$ npm run jest:coverage
```

### Style Guide

- [BEM](https://en.bem.info/)
Expand Down
4 changes: 0 additions & 4 deletions components/tooltip/__tests__/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,10 +91,8 @@ describe('Tooltip', () => {
expect(document.querySelectorAll('.hi-tooltip-right')).toHaveLength(1)
expect(document.querySelector('.hi-tooltip-right').textContent).toEqual('title')
Tooltip.close(key)
const key2 = 'key2'

expect(document.querySelectorAll('.hi-tooltip-right')).toHaveLength(0)
Tooltip.open(<Foo/>,{title,placement,key2}).close()
wrapper.unmount()
})
it('Methods target',()=>{
Expand All @@ -108,10 +106,8 @@ describe('Tooltip', () => {
expect(document.querySelectorAll('.hi-tooltip-right')).toHaveLength(1)
expect(document.querySelector('.hi-tooltip-right').textContent).toEqual('title')
legacyTarget.close(key)
const key2 = 'key2'

expect(document.querySelectorAll('.hi-tooltip-right')).toHaveLength(0)
Tooltip.open(<Foo/>,{title,placement,key2}).close()
})
})
})
Loading

0 comments on commit 062bd4b

Please sign in to comment.