66 lines
3.1 KiB
Dart
66 lines
3.1 KiB
Dart
|
|
import 'package:aitrainer_app/util/common.dart';
|
|
import 'package:test/test.dart';
|
|
|
|
main() {
|
|
late CommonHoldingClass commonClass;
|
|
setUp(() {
|
|
commonClass = CommonHoldingClass();
|
|
});
|
|
|
|
group('OneRepMax', () {
|
|
test('test OneRepMax', () async {
|
|
double weight = 60.0;
|
|
double repeats = 10;
|
|
double oneRepMax = commonClass.calculate1RM(weight, repeats);
|
|
//print("1RM: $oneRepMax");
|
|
print("1RM 100%: 1");
|
|
int repeat95 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.95);
|
|
print("1RM 95%: $repeat95");
|
|
int repeat90 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.9);
|
|
print("1RM 90%: $repeat90");
|
|
int repeat85 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.85);
|
|
print("1RM 85%: $repeat85");
|
|
int repeat83 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.82);
|
|
print("1RM 82%: $repeat83");
|
|
int repeat80 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.8);
|
|
print("1RM 80%: $repeat80");
|
|
int repeat77 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.775);
|
|
print("1RM 77,5%: $repeat77");
|
|
int repeat75 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.75);
|
|
print("1RM 75%: $repeat75");
|
|
int repeat74 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.74);
|
|
print("1RM 74%: $repeat74");
|
|
int repeat71 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.71);
|
|
print("1RM 71%: $repeat71");
|
|
int repeat70 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.7);
|
|
print("1RM 70%: $repeat70");
|
|
int repeat68 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.685);
|
|
print("1RM 68,5%: $repeat68");
|
|
int repeat65 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.65);
|
|
print("1RM 65%: $repeat65");
|
|
int repeat62 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.628);
|
|
print("1RM 62,8%: $repeat62");
|
|
int repeat60 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.6);
|
|
print("1RM 60%: $repeat60");
|
|
int repeat59 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.59);
|
|
print("1RM 59%: $repeat59");
|
|
int repeat53 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.535);
|
|
print("1RM 53,5%: $repeat53");
|
|
int repeat50 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.5);
|
|
print("1RM 50%: $repeat50");
|
|
int repeat49 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.495);
|
|
print("1RM 49,5%: $repeat49");
|
|
int repeat46 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.46);
|
|
print("1RM 45%: $repeat46");
|
|
int repeat40 = commonClass.calculateRepeatBy1RMPercent(oneRepMax, oneRepMax, 0.405);
|
|
print("1RM 40,5%: $repeat40");
|
|
|
|
expect(repeat90, 4);
|
|
expect(repeat50, 34);
|
|
|
|
|
|
|
|
});
|
|
});
|
|
} |