Skip to content

Commit

Permalink
Merge pull request #1484 from SpiNNakerManchester/mypy.bash
Browse files Browse the repository at this point in the history
Mypy.bash
  • Loading branch information
Christian-B authored Sep 10, 2024
2 parents 6f5420e + aaebdd0 commit 81b59d5
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 30 deletions.
29 changes: 29 additions & 0 deletions mypy.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#!/bin/bash

# Copyright (c) 2024 The University of Manchester
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# This bash assumes that other repositories are installed in paralled

# requires the latest mypy
# pip install --upgrade mypy

utils="../SpiNNUtils/spinn_utilities"
machine="../SpiNNMachine/spinn_machine"
man="../SpiNNMan/spinnman"
pacman="../PACMAN/pacman"
spalloc="../spalloc/spalloc_client"
fec="../SpiNNFrontEndCommon/spinn_front_end_common"

mypy $utils $machine $man $pacman $spalloc $fec spynnaker
30 changes: 0 additions & 30 deletions proxy_integration_tests/test_python_debug/check_debug.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,35 +113,5 @@ def debug(self):
sim.run(10) # second run
pop.get_data("v")
self.assertEqual(run0, SpynnakerDataView.get_run_dir_path())
# No point in checking files they are already there

sim.reset() # Soft
# check get works directly after a reset
pop.get_data("v")
sim.run(10)
found = os.listdir(SpynnakerDataView.get_run_dir_path())
self.assertIn("data1.sqlite3", found)
self.assertNotIn("ds1.sqlite3", found)

sim.reset() # soft with dsg
SpynnakerDataView.set_requires_data_generation()
sim.run(10)
pop.get_data("v")
self.assertEqual(run0, SpynnakerDataView.get_run_dir_path())
found = os.listdir(run0)
self.assertIn("data2.sqlite3", found)
self.assertIn("ds2.sqlite3", found)
# No point in checking files they are already there

sim.reset() # hard
SpynnakerDataView.set_requires_mapping()
sim.run(10)
pop.get_data("v")
self.assertNotEqual(run0, SpynnakerDataView.get_run_dir_path())
found = os.listdir(SpynnakerDataView.get_run_dir_path())
for report in reports:
self.assertIn(report, found)
self.assertIn("data3.sqlite3", found)
self.assertIn("ds3.sqlite3", found)

sim.end()

0 comments on commit 81b59d5

Please sign in to comment.