提交 8d6619e2 编写于 作者: 雪洛's avatar 雪洛

test: 调整getLocation测试数据默认值

上级 ad1e56be
...@@ -55,9 +55,10 @@ ...@@ -55,9 +55,10 @@
</scroll-view> </scroll-view>
<!-- #endif --> <!-- #endif -->
</template> </template>
<script lang="uts"> <script lang="uts">
type GetLocationType = 'wgs84' | 'gcj02'
export type LocationItem = { id : string, name : string, provider ?: UniProvider } export type LocationItem = { id : string, name : string, provider ?: UniProvider }
export type ItemType = { value : 'wgs84' | 'gcj02', name : 'wgs84' | 'gcj02' } export type ItemType = { value : GetLocationType, name : GetLocationType }
export default { export default {
data() { data() {
...@@ -81,13 +82,13 @@ ...@@ -81,13 +82,13 @@
current: 0, current: 0,
currentProvider: 0, currentProvider: 0,
jest_provider: '', jest_provider: '',
jest_type: '', jest_type: 'wgs84' as GetLocationType,
jest_isAltitude: false, jest_isAltitude: false,
jest_isGeocode: false, jest_isGeocode: false,
jest_isHighAccuracy: false, jest_isHighAccuracy: false,
jest_altitude: 0, jest_altitude: -1000,
jest_longitude: 0, jest_longitude: 200,
jest_latitude: 0, jest_latitude: 100,
jest_address: '', jest_address: '',
jest_errCode: 0, jest_errCode: 0,
jest_complete: false jest_complete: false
...@@ -222,7 +223,7 @@ ...@@ -222,7 +223,7 @@
this.jest_altitude = res.altitude this.jest_altitude = res.altitude
this.jest_complete = true this.jest_complete = true
}, },
fail: (err ) => { fail: (err) => {
this.jest_errCode = err.errCode this.jest_errCode = err.errCode
this.jest_complete = true this.jest_complete = true
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册