好吧,我已经为此烦恼了几天。因此,我最终将向StackOverflow的优秀人员寻求急需的帮助:)
Here is the error I'm getting => Identifier 'global' has already been declared
And it seems to not recognize the require keyword
因此,目前,测试套件的50%通过了。
它似乎仅在调用redux reducers的测试中抛出。由于几乎所有失败的测试的错误都是相同的。
这是我当前的df1 = pd.DataFrame({'col1':[1,2,3,None,5], 'col2':[25,5,None,None,1],
'col3':[40,3,None,None,None]}, index=[datetime.date(2015,7,7),datetime.date(2015,7,12),datetime.date(2015,8,1),datetime.date(2015,8,10),datetime.date(2015,9,20)])
df2 = pd.DataFrame({'col1':[14,82,None,None,1], 'col2':[5,5,None,4,1], 'col3':[4,3,5,None,6]},
index=[datetime.date(2015,7,10),datetime.date(2015,7,15),datetime.date(2015,8,4),datetime.date(2015,8,12),datetime.date(2015,9,25)])
df3 = pd.DataFrame({'col1':[10,9,None,None,15], 'col2':[None,5,None,3,1], 'col3':[None,3,3,1,74]},
index=[datetime.date(2015,7,5),datetime.date(2015,8,1),datetime.date(2015,8,9),datetime.date(2015,8,10),datetime.date(2015,9,20)])
fig=plt.figure(figsize=(15, 15))
ax1 = plt.subplot(313)
ax2 = plt.subplot(312, sharex = ax1)
ax3 = plt.subplot(311, sharex = ax1)
for column in df1.columns:
ax1 = plt.scatter(df1.index, df1[column], s=2)
for column in df2.columns:
ax2 = plt.scatter(df2.index, df2[column], s=2)
for column in df3.columns:
ax3 = plt.scatter(df3.index, df3[column], s=2)
plt.show()
babel.config.js
依赖项位于
module.exports = function(api) {
const isTest = api.env('test')
const presets = [
isTest && [
'@babel/preset-env',
{
targets: {
node: 'current',
},
},
],
[
'next/babel',
{
'preset-env': {},
'transform-runtime': {},
'styled-jsx': {},
'class-properties': {},
},
],
].filter(Boolean)
const plugins = ['babel-plugin-styled-components']
return {
presets,
plugins,
sourceType: 'unambiguous',
}
}