-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
944 changed files
with
34,318 additions
and
4,120 deletions.
There are no files selected for viewing
Binary file not shown.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,31 @@ | ||
# xUnit For 1C - Set of unit testing tools for 1C:Enterprise 8 platform | ||
# xUnitFor1C - Set of testing tools for 1C:Enterprise 8 platform | ||
|
||
xUnit For 1C is a set of unit testing tools for 1C:Enterprise 8 platform (http://v8.1c.ru). | ||
xUnitFor1C is a set of testing tools for 1C:Enterprise 8 platform (http://v8.1c.ru). | ||
|
||
xUnit для 1С - набор инструментов для выполнения юнит-тестирования (модульного тестирования) в 1С:Предприятии 8. | ||
xUnitFor1C - набор инструментов для выполнения тестирования (модульного/юнит, приемочного, сценарного для 1С 8.3, интеграционного) в 1С:Предприятии 8. | ||
|
||
## Что к чему | ||
|
||
* *UnitTestRunner.epf* - браузер и исполнитель тестов для обычного приложения 1С:Предприятия 8 | ||
* *TestRunner.js* - скрипт для Снегопата, позволяющий выполнять тесты прямо из конфигуратора | ||
* *Тесты/* - каталог с примерами тестов и с тестами для самотестирования UnitTestRunner.epf (подпапка selftests) | ||
[Посмотрите Wiki](https://github.com/xDrivenDevelopment/xUnitFor1C/wiki) | ||
|
||
### Возможности UnitTestRunner.epf | ||
## Что к чему | ||
|
||
UnitTestRunner.epf почти полнофункционален - умеет загружать тесты из произвольно выбранного каталога и выполнять все загруженные тесты скопом. | ||
По одному тесту пока запускать не умеет. | ||
* *xddTestRunner.epf* - браузер и исполнитель тестов для обычного приложения и управляемого приложения 1С:Предприятия 8 (толстый и тонкий клиенты) | ||
* *xddTestRunner.js* - скрипт для Снегопата, позволяющий выполнять тесты прямо из конфигуратора | ||
* *Тесты/* - каталог с примерами тестов и с тестами для самотестирования xddTestRunner.epf (подпапка selftests) | ||
|
||
### Ограничения TestRunner.js | ||
### Ограничения xddTestRunner.js | ||
|
||
TestRunner.js пока находится в состоянии "proof of concept" и для практического применения бесполезен. | ||
xddTestRunner.js пока находится в состоянии "proof of concept" и для практического применения бесполезен. | ||
Имеют место быть следующие ограничения: | ||
|
||
1. Работает только макрос "Выполнить все тесты", остальные макросы не работают. | ||
2. Выполняются тесты из жестко прописанного каталога <Каталог Снегопата>\user\1CUnit\Тесты | ||
|
||
В виду п. 2. содержимое репозитария надо разместить там, в ближайшее время планируется это неудобство устранить. | ||
|
||
## Как помочь проекту | ||
|
||
Мы рады любой помощи: | ||
|
||
1. Если вы занимаетесь разработкой на 1С:Преприятии 8 пробуйте писать и выполнять тесты при помощи 1CUnit, сообщайте нам об обнаруженных ошибках, пишите пожелания. Для управления сообщениями об ошибках и пожеланиями мы используем [баг-трекер GitHub'а](https://github.com/kuntashov/1CUnit/issues?sort=created&state=open). | ||
1. Если вы занимаетесь разработкой на 1С:Преприятии 8 пробуйте писать и выполнять тесты при помощи xUnitFor1C, сообщайте нам об обнаруженных ошибках, пишите пожелания. Для управления сообщениями об ошибках и пожеланиями мы используем [баг-трекер GitHub'а](https://github.com/xDrivenDevelopment/xUnitFor1C/issues?sort=created&state=open). | ||
|
||
2. Если у вас есть время разобраться в исходном коде, вы можете взять на себя реализацию одной из [открытых задач](https://github.com/kuntashov/xUnitFor1C/issues?sort=created&state=open). | ||
2. Если у вас есть время разобраться в исходном коде, вы можете взять на себя реализацию одной из [открытых задач](https://github.com/xDrivenDevelopment/xUnitFor1C/issues?sort=created&state=open). | ||
|
||
3. Если вы уже используете xUnit For 1C на практике, напишите об этом статью, например, на [Инфостарте](http://infostart.ru). | ||
3. Если вы уже используете xUnitFor1C на практике, напишите об этом статью, например, на [Инфостарте](http://infostart.ru). |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File renamed without changes.
Binary file renamed
BIN
+4.46 KB
Тесты/ТестОткрытиеОбработкиПоказатьGUID.epf → ...App/ТестОткрытиеОбработкиПоказатьGUID.epf
Binary file not shown.
File renamed without changes.
Binary file renamed
BIN
+48.6 KB
Тесты/ТестыГенератораДанных1CUnit.epf → Tests/CommonApp/ТестыГенератораДанных.epf
Binary file not shown.
Binary file not shown.
File renamed without changes.
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file renamed
BIN
+6.85 KB
...ние/selftests/ТестыПроверитьВыполнить.epf → ...App/selftests/ТестыПроверитьВыполнить.epf
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file renamed
BIN
+6.48 KB
...яемое приложение/Тест_ПараметрыТестов.epf → Tests/ManagedApp/Тест_ПараметрыТестов.epf
Binary file not shown.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
#"C:\Program Files (x86)\1cv82\8.2.18.96\bin\1cv8c.exe" /DisableStartupMessages /Execute E:\ТестыИМ\xddTestRunner.epf /S "as-msk-a6122\im_test" /Out "E:\ТестыИМ\Тесты\log.txt" /C "Тесты_Команда_Тестировать;E:\ТестыИМ\Тесты;ЗавершитьРаботуПослеТестирования" /LogUI | ||
@' | ||
if ($args.count -gt 0) { $basePath = args[0] } | ||
else { $basePath = "C:\Users\aayuhanov\Documents\1c\1cv77\Конфигурации\АвтообновлениеКонфигурации" } | ||
$bin1c = "${env:ProgramFiles(x86)}\1cv77\BIN.SQL\1cv7s.exe" | ||
If (!(Test-Path $bin1c)) { | ||
$bin1c = "$env:ProgramFiles\1cv77\BIN.SQL\1cv7s.exe" | ||
} | ||
$bin1c | ||
$basePath | ||
#start "" /wait %bin1c% config /m /D"$basePath\База" /loadmd"$basePath\База_1Cv7.MD" | ||
Start-Process $bin1c "config /m /D""$basePath\База"" /loadmd""$basePath\База_1Cv7.MD"" " -Wait | ||
Get-Content d:\ЗагрузкаОбъединениеМД.log | ||
"." | ||
Start-Process $bin1c "config /m /D""$basePath\База"" /loadmd""$basePath\УдалилСпр_ИзменилТипРеквизита_1Cv7.MD"" " -Wait | ||
Get-Content d:\ЗагрузкаОбъединениеМД.log | ||
'@ | ||
|
||
if ($args.count -gt 0) { $basePath = args[0] } | ||
else { $basePath = "W:\1CUnit\ТестоваяБаза" } | ||
|
||
if ($args.count -gt 1) { $TestRunnerPath = args[1] } | ||
else { $TestRunnerPath = "C:\Projects\GitHub\xUnitFor1C\xddTestRunner.epf" } | ||
|
||
if ($args.count -gt 2) { $TestsPath = args[2] } | ||
else { $TestsPath = "C:\Projects\GitHub\xUnitFor1C\Tests\CommonApp\ТестПримерТеста.epf" } | ||
#else { $TestsPath = "C:\Projects\GitHub\xUnitFor1C\Tests\selftests" } | ||
#else { $TestsPath = "Метаданные.Подсистемы.Тестовая" } | ||
|
||
$bin1c = "${env:ProgramFiles(x86)}\1cv82\8.2.19.68\bin\1cv8.exe" | ||
#$bin1c = "${env:ProgramFiles(x86)}\1cv82\8.2.19.68\bin\1cv8c.exe" | ||
@' | ||
If (!(Test-Path $bin1c)) { | ||
$bin1c = "$env:ProgramFiles\1cv77\BIN.SQL\1cv7s.exe" | ||
} | ||
'@ | ||
$logPath = "D:\log.txt" | ||
|
||
$bin1c | ||
$basePath | ||
$TestRunnerPath | ||
$TestsPath | ||
|
||
#start "" /wait %bin1c% config /m /D"$basePath\База" /loadmd"$basePath\База_1Cv7.MD" | ||
#"C:\Program Files (x86)\1cv82\8.2.18.96\bin\1cv8c.exe" /DisableStartupMessages /Execute E:\ТестыИМ\xddTestRunner.epf /S "as-msk-a6122\im_test" /Out "E:\ТестыИМ\Тесты\log.txt" /C "Тесты_Команда_Тестировать;E:\ТестыИМ\Тесты;ЗавершитьРаботуПослеТестирования" /LogUI | ||
Start-Process $bin1c " /F ""$basePath"" /NАдминистратор /DisableStartupMessages /Execute $TestRunnerPath /Out $logPath /C ""xddRun;$TestsPath;xddShutdown1"" /LogUI " -Wait | ||
Get-Content $logPath | ||
|
||
"." |
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file not shown.
Binary file renamed
BIN
+4.61 KB
Тесты/selftests/ТестыПроверитьВыполнить.epf → Tests/selftests/ТестыПроверитьВыполнить.epf
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file renamed
BIN
+4.79 KB
...ыУтверждения_ПроверитьРавенствоФайлов.epf → ...ыУтверждения_ПроверитьРавенствоФайлов.epf
Binary file not shown.
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file renamed
BIN
+4.25 KB
...utomated/1CUnit/Тесты/ТестПримерТеста.epf → ...utomated/1CUnit/Тесты/ТестПримерТеста.epf
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
@echo off | ||
rem | ||
rem ’¥áâ¨à®¢ ¨¥ ¯¥à¥ª«îç¥¨ï ¢¥â®ª åà ¨«¨é xUnitFor1C | ||
rem | ||
rem ’ॡ®¢ ¨ï: | ||
rem 1. “áâ ®¢«¥ë© Git. ãâì ª ¥¬ã 室¨âìáï ¢ á¨á⥬®¬ PATH. | ||
rem 2. „®áâ㯠ª á ©âã GitHub - https://github.com/xDrivenDevelopment/xUnitFor1C | ||
rem | ||
rem ਬ¥à ¢ë§®¢ (¯¥à¥ª«î票ï master <-> develop ¨ ®¡à â®): | ||
rem git_xUnitFor1C_check.cmd | ||
rem ¨«¨ (¯¥à¥ª«î票ï master <-> develop <-> ˆ¬ï„®¯‚¥âª¨ ¨ ®¡à â®): | ||
rem git_xUnitFor1C_check.cmd ˆ¬ï„®¯‚¥âª¨ | ||
rem | ||
|
||
setlocal | ||
if "%1"=="" ( set branch=develop | ||
) else ( | ||
set branch=%1 | ||
) | ||
rem echo %branch% | ||
|
||
set git_cmd=git | ||
if EXIST "%LOCALAPPDATA%\Atlassian\SourceTree\git_local\cmd\git.exe" set git_cmd="%LOCALAPPDATA%\Atlassian\SourceTree\git_local\cmd\git.exe" | ||
|
||
set remoteRepo=https://github.com/xDrivenDevelopment/xUnitFor1C.git | ||
rem set remoteRepo=C:\Projects\xUnitFor1C_t1\.git | ||
|
||
set repo=%CD%\xUnitFor1C_temp831 | ||
|
||
rem echo %repo% | ||
|
||
rd /S /Q %repo% | ||
if EXIST %repo% ( | ||
tskill TGitCache | ||
rd /S /Q %repo% | ||
if EXIST %repo% ( | ||
echo ¥ 㤠«®áì 㤠«¨âì ª â «®£ %repo% | ||
exit 1 | ||
pause | ||
) | ||
) | ||
|
||
md %repo% | ||
|
||
%git_cmd% -c diff.mnemonicprefix=false -c core.quotepath=false clone --recursive %remoteRepo% %repo% | ||
|
||
set old_branch=master | ||
cd %repo% | ||
%git_cmd% checkout -b develop origin/develop | ||
if errorlevel 1 ( | ||
echo . | ||
echo ¥ 㤠«®áì ¯¥à¥ª«îç¨âìáï ¢¥âªã develop ¨§ ¢¥âª¨ %old_branch% | ||
pause | ||
exit 2 | ||
) | ||
%git_cmd% status | ||
set old_branch=develop | ||
|
||
if not %branch%==develop ( | ||
%git_cmd% checkout -b %branch% origin/%branch% | ||
if errorlevel 1 ( | ||
echo . | ||
echo ¥ 㤠«®áì ¯¥à¥ª«îç¨âìáï ¢¥âªã %branch% ¨§ ¢¥âª¨ %old_branch% | ||
pause | ||
exit 5 | ||
) | ||
%git_cmd% status | ||
set old_branch=%branch% | ||
) | ||
|
||
%git_cmd% checkout master | ||
if errorlevel 1 ( | ||
echo . | ||
echo ¥ 㤠«®áì ¯¥à¥ª«îç¨âìáï ¢¥âªã master ¨§ ¢¥âª¨ %old_branch% | ||
pause | ||
exit 3 | ||
) | ||
%git_cmd% status | ||
set old_branch=master | ||
|
||
%git_cmd% checkout develop | ||
if errorlevel 1 ( | ||
echo . | ||
echo ¥ 㤠«®áì ¯®¢â®à® ¯¥à¥ª«îç¨âìáï ¢¥âªã develop ¨§ ¢¥âª¨ %old_branch% | ||
pause | ||
exit 4 | ||
) | ||
%git_cmd% status | ||
set old_branch=develop | ||
|
||
if not %branch%==develop ( | ||
%git_cmd% checkout %branch% | ||
if errorlevel 1 ( | ||
echo . | ||
echo ¥ 㤠«®áì ¯®¢â®à® ¯¥à¥ª«îç¨âìáï ¢¥âªã %branch% ¨§ ¢¥âª¨ %old_branch% | ||
pause | ||
exit 6 | ||
) | ||
%git_cmd% status | ||
set old_branch=%branch% | ||
) | ||
|
||
%git_cmd% checkout master | ||
if errorlevel 1 ( | ||
echo . | ||
echo ¥ 㤠«®áì ¯®¢â®à® ¯¥à¥ª«îç¨âìáï ¢¥âªã master ¨§ ¢¥âª¨ %old_branch% | ||
pause | ||
exit 7 | ||
) | ||
%git_cmd% status | ||
set old_branch=master | ||
|
||
endlocal | ||
echo ‚ᥠ¯¥à¥ª«îç¥¨ï § ¢¥à訫¨áì ãá¯¥è® | ||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.