自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(7)
  • 收藏
  • 关注

原创 解决Mac环境下gradle报错

1.报错信息Gradle sync failed: Could not HEAD ‘https://maven.aliyun.com/nexus/content/groups/public/com/android/tools/build/gradle/3.4.1/gradle-3.4.1.pom’. Received status code 400 from server: Bad Request2.解决办法文件夹->前往文件夹->输入(~/.gradle)->打开grad

2021-02-05 16:40:38 692

原创 解决Mac安装git安装包时报错443问题

问题描述:Mac运行brew install xxx 报错报错信息:fatal: unable to access ‘https://github.com/Homebrew/homebrew-core/’: Failed to connect to github.com port 443: Operation timed out原因分析:GitHub无法访问解决方案:修改hosts文件查询域名对应的dns网站:http://tool.chinaz.com/dns?输入域名查询出对应的dns

2020-11-16 14:50:39 1533

原创 adb命令模拟Android电量

adb命令模拟Android电量查看手机电量信息adb shell dumpsys battery模拟手机充电状态adb shell dumpsys battery set status 2模拟手机为非充电状态adb shell dumpsys battery set status 1模拟手机断开充电adb shell dumpsys battery unplug模拟手机电量adb shell dumpsys battery set level XX 代表电池百分比

2020-07-29 15:45:35 5508

原创 Mac OS修改默认的python2为python3(alias起别名法)

1. 查看Mac的python版本为python2python --version2. 在命令行查看python3的位置3. 新建/修改.bash_profilevi .bash_profile4. 编辑.bash_profile用alias给python命令 起个别名,定位到python35. 使.bash_profile生效source ./bash_profile6. 查...

2020-02-16 23:08:56 1805

原创 react-redux 之 connect mapStateToProps 测试数据无效的解决

首先明确mapStateToProps中有参数有两种形式 一个参数--store state 调用情况:store的state改变时两个参数--store state和the wrapper componnet's props调用情况:1.store的state改变时 2.当被包装的component接收新的state时然后明确mapStateToProps中返回值会被合并到被...

2019-01-29 15:06:19 607

原创 Jest测试react native中遇到的Animated

Animated的官方文档:https://facebook.github.io/react-native/docs/animated解决方案 mock function + jest.useFakeTimers();注意:mock function一定要mock到最外面一层,否则mock start()方法时会报错 TypeError: animation._isUsingNative...

2019-01-09 18:38:30 205

原创 JEST 测试中如何定位到connect() 返回的没有导出的类

在被测class没有导出的情况下,shallow之后的wrapper对象需要dive到对应的class(wrapper.dive().instance()),才能获得class对应的方法或者state在被测class已经导出的情况下,shallow之后的wrapper对象直接利用instance(wrapper.instance())获得class对应的方法或者state...

2019-01-09 11:00:30 468 1

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除